Commit 571a3248 authored by Matthias Betz's avatar Matthias Betz
Browse files

update model for citygml4j 3 and quality ade 1.4.0

parent 009cef54
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.AbstractPolygonError;
public class AbstractPolygonErrorProperty extends AbstractInlineProperty<AbstractPolygonError> implements ADEObject {
@Serial
private static final long serialVersionUID = 70692012962059529L;
public AbstractPolygonErrorProperty() {
super();
}
public AbstractPolygonErrorProperty(AbstractPolygonError ape) {
super(ape);
}
@Override
public Class<AbstractPolygonError> getTargetType() {
return AbstractPolygonError.class;
}
}
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.AbstractRingError;
public class AbstractRingErrorProperty extends AbstractInlineProperty<AbstractRingError> implements ADEObject {
@Serial
private static final long serialVersionUID = 6934180997181643185L;
public AbstractRingErrorProperty() {
super();
}
public AbstractRingErrorProperty(AbstractRingError are) {
super(are);
}
@Override
public Class<AbstractRingError> getTargetType() {
return AbstractRingError.class;
}
}
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.AbstractSemanticError;
public class AbstractSemanticErrorProperty extends AbstractInlineProperty<AbstractSemanticError> implements ADEObject {
@Serial
private static final long serialVersionUID = 8488922114751949334L;
public AbstractSemanticErrorProperty() {
super();
}
public AbstractSemanticErrorProperty(AbstractSemanticError ase) {
super(ase);
}
@Override
public Class<AbstractSemanticError> getTargetType() {
return AbstractSemanticError.class;
}
}
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.AbstractSolidError;
public class AbstractSolidErrorProperty extends AbstractInlineProperty<AbstractSolidError> implements ADEObject {
@Serial
private static final long serialVersionUID = 4191279461525842687L;
public AbstractSolidErrorProperty() {
super();
}
public AbstractSolidErrorProperty(AbstractSolidError ase) {
super(ase);
}
@Override
public Class<AbstractSolidError> getTargetType() {
return AbstractSolidError.class;
}
}
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.AllPolygonsOrientedWrongError;
public class AllPolygonsOrientedWrongErrorProperty extends AbstractInlineProperty<AllPolygonsOrientedWrongError> implements ADEObject {
@Serial
private static final long serialVersionUID = 441706560214349475L;
public AllPolygonsOrientedWrongErrorProperty() {
super();
}
public AllPolygonsOrientedWrongErrorProperty(AllPolygonsOrientedWrongError apowe) {
super(apowe);
}
@Override
public Class<AllPolygonsOrientedWrongError> getTargetType() {
return AllPolygonsOrientedWrongError.class;
}
}
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.Checking;
public class CheckingProperty extends AbstractInlineProperty<Checking> implements ADEObject {
@Serial
private static final long serialVersionUID = 2275964563754871682L;
public CheckingProperty() {
super();
}
public CheckingProperty(Checking c) {
super(c);
}
@Override
public Class<Checking> getTargetType() {
return Checking.class;
}
}
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.ComponentList;
public class ComponentListProperty extends AbstractInlineProperty<ComponentList> implements ADEObject {
@Serial
private static final long serialVersionUID = 3081945215746143126L;
public ComponentListProperty() {
super();
}
public ComponentListProperty(ComponentList cl) {
super(cl);
}
@Override
public Class<ComponentList> getTargetType() {
return ComponentList.class;
}
}
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.ConsecutivePointsSameError;
public class ConsecutivePointsSameErrorProperty extends AbstractInlineProperty<ConsecutivePointsSameError> implements ADEObject {
@Serial
private static final long serialVersionUID = 3869036308848839709L;
public ConsecutivePointsSameErrorProperty() {
super();
}
public ConsecutivePointsSameErrorProperty(ConsecutivePointsSameError cpse) {
super(cpse);
}
@Override
public Class<ConsecutivePointsSameError> getTargetType() {
return ConsecutivePointsSameError.class;
}
}
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.EdgeList;
public class EdgeListProperty extends AbstractInlineProperty<EdgeList> implements ADEObject {
@Serial
private static final long serialVersionUID = 2336457353379630637L;
public EdgeListProperty() {
super();
}
public EdgeListProperty(EdgeList el) {
super(el);
}
@Override
public Class<EdgeList> getTargetType() {
return EdgeList.class;
}
}
/*- /*-
* Copyright 2020 Hochschule für Technik Stuttgart * Copyright 2022 Hochschule für Technik Stuttgart
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
...@@ -13,32 +13,31 @@ ...@@ -13,32 +13,31 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
package de.hft.stuttgart.quality.model.jaxb; package de.hft.stuttgart.quality.model.properties;
import javax.xml.bind.annotation.XmlAccessType; import java.io.Serial;
import javax.xml.bind.annotation.XmlAccessorType;
import net.opengis.gml.DirectPositionType; import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
@XmlAccessorType(XmlAccessType.FIELD) import de.hft.stuttgart.quality.model.types.Edge;
public class EdgeType {
private DirectPositionType from; public class EdgeProperty extends AbstractInlineProperty<Edge> implements ADEObject {
private DirectPositionType to;
public void setFrom(DirectPositionType from) { @Serial
this.from = from; private static final long serialVersionUID = 3087019382945722678L;
}
public void setTo(DirectPositionType to) { public EdgeProperty() {
this.to = to; super();
} }
public DirectPositionType getFrom() { public EdgeProperty(Edge e) {
return from; super(e);
} }
@Override
public Class<Edge> getTargetType() {
return Edge.class;
}
public DirectPositionType getTo() {
return to;
}
} }
/*- /*-
* Copyright 2020 Hochschule für Technik Stuttgart * Copyright 2022 Hochschule für Technik Stuttgart
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
...@@ -13,30 +13,31 @@ ...@@ -13,30 +13,31 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
package de.hft.stuttgart.quality.model.jaxb; package de.hft.stuttgart.quality.model.properties;
import javax.xml.bind.annotation.XmlRootElement; import java.io.Serial;
@XmlRootElement(name = "GE_P_INNER_RINGS_NESTED") import org.citygml4j.core.model.ade.ADEObject;
public class InnerRingsNestedType extends PolygonErrorType { import org.xmlobjects.gml.model.base.AbstractInlineProperty;
private String linearRingId1; import de.hft.stuttgart.quality.model.types.Error;
private String linearRingId2;
public void setLinearRingId1(String linearRingId1) { public class ErrorProperty extends AbstractInlineProperty<Error> implements ADEObject {
this.linearRingId1 = linearRingId1;
}
public void setLinearRingId2(String linearRingId2) { @Serial
this.linearRingId2 = linearRingId2; private static final long serialVersionUID = 1405693040162674820L;
}
public String getLinearRingId1() { public ErrorProperty() {
return linearRingId1; super();
} }
public String getLinearRingId2() { public ErrorProperty(Error e) {
return linearRingId2; super(e);
} }
@Override
public Class<Error> getTargetType() {
return Error.class;
}
} }
/*- /*-
* Copyright 2020 Hochschule für Technik Stuttgart * Copyright 2022 Hochschule für Technik Stuttgart
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
...@@ -13,37 +13,31 @@ ...@@ -13,37 +13,31 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
package de.hft.stuttgart.quality.model; package de.hft.stuttgart.quality.model.properties;
import java.util.ArrayList; import java.io.Serial;
import java.util.List;
import org.citygml4j.core.model.ade.ADEObject;
import org.citygml4j.builder.copy.CopyBuilder; import org.xmlobjects.gml.model.base.AbstractInlineProperty;
public class PolygonWrongOrientation extends SolidError { import de.hft.stuttgart.quality.model.types.FeatureStatistics;
private static final long serialVersionUID = 1128689472694838648L; public class FeatureStatisticsProperty extends AbstractInlineProperty<FeatureStatistics> implements ADEObject {
private List<Edge> edges; @Serial
private static final long serialVersionUID = 4725452691563906950L;
public boolean isSetEdges() {
return edges != null && !edges.isEmpty(); public FeatureStatisticsProperty() {
} super();
}
public List<Edge> getEdges() {
if (edges == null) { public FeatureStatisticsProperty(FeatureStatistics fs) {
edges = new ArrayList<>(); super(fs);
} }
return edges;
} @Override
public Class<FeatureStatistics> getTargetType() {
@Override return FeatureStatistics.class;
public String toString() { }
return "PolygonWrongOrientation [geometryId=" + getGeometryId() + ", edges=" + edges + "]";
}
@Override
public Object copy(CopyBuilder copyBuilder) {
return copyTo(new PolygonWrongOrientation(), copyBuilder);
}
} }
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.Filter;
public class FilterProperty extends AbstractInlineProperty<Filter> implements ADEObject {
@Serial
private static final long serialVersionUID = 2202767186145199981L;
public FilterProperty() {
super();
}
public FilterProperty(Filter f) {
super(f);
}
@Override
public Class<Filter> getTargetType() {
return Filter.class;
}
}
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.GlobalParameters;
public class GlobalParametersProperty extends AbstractInlineProperty<GlobalParameters> implements ADEObject {
@Serial
private static final long serialVersionUID = 4688667898762529244L;
public GlobalParametersProperty() {
super();
}
public GlobalParametersProperty(GlobalParameters gp) {
super(gp);
}
@Override
public Class<GlobalParameters> getTargetType() {
return GlobalParameters.class;
}
}
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.HoleOutsideError;
public class HoleOutsideErrorProperty extends AbstractInlineProperty<HoleOutsideError> implements ADEObject {
@Serial
private static final long serialVersionUID = 4196743912365692331L;
public HoleOutsideErrorProperty() {
super();
}
public HoleOutsideErrorProperty(HoleOutsideError gepholeoutside) {
super(gepholeoutside);
}
@Override
public Class<HoleOutsideError> getTargetType() {
return HoleOutsideError.class;
}
}
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.InnerRingsNestedError;
public class InnerRingsNestedErrorProperty extends AbstractInlineProperty<InnerRingsNestedError> implements ADEObject {
@Serial
private static final long serialVersionUID = 3036689276151551958L;
public InnerRingsNestedErrorProperty() {
super();
}
public InnerRingsNestedErrorProperty(InnerRingsNestedError irne) {
super(irne);
}
@Override
public Class<InnerRingsNestedError> getTargetType() {
return InnerRingsNestedError.class;
}
}
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.InteriorDisconnectedError;
public class InteriorDisconnectedErrorProperty extends AbstractInlineProperty<InteriorDisconnectedError> implements ADEObject {
@Serial
private static final long serialVersionUID = 84761615612278576L;
public InteriorDisconnectedErrorProperty() {
super();
}
public InteriorDisconnectedErrorProperty(InteriorDisconnectedError ide) {
super(ide);
}
@Override
public Class<InteriorDisconnectedError> getTargetType() {
return InteriorDisconnectedError.class;
}
}
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.IntersectingRingsError;
public class IntersectingRingsErrorProperty extends AbstractInlineProperty<IntersectingRingsError> implements ADEObject {
@Serial
private static final long serialVersionUID = 1608106125509503698L;
public IntersectingRingsErrorProperty() {
super();
}
public IntersectingRingsErrorProperty(IntersectingRingsError ire) {
super(ire);
}
@Override
public Class<IntersectingRingsError> getTargetType() {
return IntersectingRingsError.class;
}
}
/*- /*-
* Copyright 2020 Hochschule für Technik Stuttgart * Copyright 2022 Hochschule für Technik Stuttgart
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
...@@ -13,31 +13,31 @@ ...@@ -13,31 +13,31 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
package de.hft.stuttgart.quality.marshaller; package de.hft.stuttgart.quality.model.properties;
import java.time.LocalDateTime; import java.io.Serial;
import java.time.ZoneId;
import java.time.ZonedDateTime; import org.citygml4j.core.model.ade.ADEObject;
import java.time.format.DateTimeFormatter; import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import javax.xml.bind.annotation.adapters.XmlAdapter; import de.hft.stuttgart.quality.model.types.MultipleComponentsError;
public class ZonedDateTimeAdapter extends XmlAdapter<String, ZonedDateTime> { public class MultipleComponentsErrorProperty extends AbstractInlineProperty<MultipleComponentsError> implements ADEObject {
@Override @Serial
public ZonedDateTime unmarshal(String v) throws Exception { private static final long serialVersionUID = 5294284044767336204L;
try {
return ZonedDateTime.from(DateTimeFormatter.ISO_OFFSET_DATE_TIME.parse(v)); public MultipleComponentsErrorProperty() {
} catch (Exception e) { super();
return LocalDateTime.parse(v).atZone(ZoneId.systemDefault()); }
}
} public MultipleComponentsErrorProperty(MultipleComponentsError mce) {
super(mce);
@Override }
public String marshal(ZonedDateTime v) throws Exception {
return DateTimeFormatter.ISO_OFFSET_DATE_TIME.format(v); @Override
} public Class<MultipleComponentsError> getTargetType() {
return MultipleComponentsError.class;
}
} }
/*-
* Copyright 2022 Hochschule für Technik Stuttgart
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.hft.stuttgart.quality.model.properties;
import java.io.Serial;
import org.citygml4j.core.model.ade.ADEObject;
import org.xmlobjects.gml.model.base.AbstractInlineProperty;
import de.hft.stuttgart.quality.model.types.NonManifoldEdgeError;
public class NonManifoldEdgeErrorProperty extends AbstractInlineProperty<NonManifoldEdgeError> implements ADEObject {
@Serial
private static final long serialVersionUID = 8331219256576062664L;
public NonManifoldEdgeErrorProperty() {
super();
}
public NonManifoldEdgeErrorProperty(NonManifoldEdgeError nmee) {
super(nmee);
}
@Override
public Class<NonManifoldEdgeError> getTargetType() {
return NonManifoldEdgeError.class;
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment