diff options
author | 2018-03-30 18:22:32 +0530 | |
---|---|---|
committer | 2018-03-30 18:22:32 +0530 | |
commit | d2009aeed90083a9a4e5d2c3e525ca4b80a183b9 (patch) | |
tree | fb57be0004f38fd0f427b4e42790ffd231f7b5c8 /UniversalVesAdapter | |
parent | 00a00a68862effd791ce3f127d0ddd5903598b89 (diff) |
Adding Some Files and TestCases in Mapper
Adding Some Files and TestCases in Universal Adapter in Mapper
Issue-ID: DCAEGEN2-335
Change-Id: Iecb5500b1b856b9f1f8558334219adb59b293e10
Signed-off-by: Pooja03 <PM00501616@techmahindra.com>
Diffstat (limited to 'UniversalVesAdapter')
65 files changed, 8872 insertions, 31 deletions
diff --git a/UniversalVesAdapter/.classpath b/UniversalVesAdapter/.classpath new file mode 100644 index 0000000..6d7587a --- /dev/null +++ b/UniversalVesAdapter/.classpath @@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="UTF-8"?> +<classpath> + <classpathentry kind="src" output="target/classes" path="src/main/java"> + <attributes> + <attribute name="optional" value="true"/> + <attribute name="maven.pomderived" value="true"/> + </attributes> + </classpathentry> + <classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources"> + <attributes> + <attribute name="maven.pomderived" value="true"/> + </attributes> + </classpathentry> + <classpathentry kind="src" output="target/test-classes" path="src/test/java"> + <attributes> + <attribute name="optional" value="true"/> + <attribute name="maven.pomderived" value="true"/> + </attributes> + </classpathentry> + <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"> + <attributes> + <attribute name="maven.pomderived" value="true"/> + </attributes> + </classpathentry> + <classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER"> + <attributes> + <attribute name="maven.pomderived" value="true"/> + </attributes> + </classpathentry> + <classpathentry kind="output" path="target/classes"/> +</classpath> diff --git a/UniversalVesAdapter/.project b/UniversalVesAdapter/.project new file mode 100644 index 0000000..473a65c --- /dev/null +++ b/UniversalVesAdapter/.project @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="UTF-8"?> +<projectDescription> + <name>UniversalVesAdapter</name> + <comment></comment> + <projects> + </projects> + <buildSpec> + <buildCommand> + <name>org.eclipse.wst.common.project.facet.core.builder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.jdt.core.javabuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.springframework.ide.eclipse.core.springbuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.m2e.core.maven2Builder</name> + <arguments> + </arguments> + </buildCommand> + </buildSpec> + <natures> + <nature>org.springframework.ide.eclipse.core.springnature</nature> + <nature>org.eclipse.jdt.core.javanature</nature> + <nature>org.eclipse.m2e.core.maven2Nature</nature> + <nature>org.eclipse.wst.common.project.facet.core.nature</nature> + </natures> +</projectDescription> diff --git a/UniversalVesAdapter/.settings/org.eclipse.core.resources.prefs b/UniversalVesAdapter/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 0000000..839d647 --- /dev/null +++ b/UniversalVesAdapter/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,5 @@ +eclipse.preferences.version=1 +encoding//src/main/java=UTF-8 +encoding//src/main/resources=UTF-8 +encoding//src/test/java=UTF-8 +encoding/<project>=UTF-8 diff --git a/UniversalVesAdapter/.settings/org.eclipse.jdt.core.prefs b/UniversalVesAdapter/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 0000000..714351a --- /dev/null +++ b/UniversalVesAdapter/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,5 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 +org.eclipse.jdt.core.compiler.compliance=1.8 +org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning +org.eclipse.jdt.core.compiler.source=1.8 diff --git a/UniversalVesAdapter/.settings/org.eclipse.m2e.core.prefs b/UniversalVesAdapter/.settings/org.eclipse.m2e.core.prefs new file mode 100644 index 0000000..f897a7f --- /dev/null +++ b/UniversalVesAdapter/.settings/org.eclipse.m2e.core.prefs @@ -0,0 +1,4 @@ +activeProfiles= +eclipse.preferences.version=1 +resolveWorkspaceProjects=true +version=1 diff --git a/UniversalVesAdapter/.settings/org.eclipse.wst.common.project.facet.core.xml b/UniversalVesAdapter/.settings/org.eclipse.wst.common.project.facet.core.xml new file mode 100644 index 0000000..d858295 --- /dev/null +++ b/UniversalVesAdapter/.settings/org.eclipse.wst.common.project.facet.core.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="UTF-8"?> +<faceted-project> + <installed facet="cloudfoundry.standalone.app" version="1.0"/> +</faceted-project> diff --git a/UniversalVesAdapter/pom.xml b/UniversalVesAdapter/pom.xml index a4929d5..0649cd0 100644 --- a/UniversalVesAdapter/pom.xml +++ b/UniversalVesAdapter/pom.xml @@ -91,6 +91,13 @@ <artifactId>xstream</artifactId> <version>1.4.10</version> </dependency> +<!-- https://mvnrepository.com/artifact/xml-apis/xml-apis --> +<dependency> + <groupId>xml-apis</groupId> + <artifactId>xml-apis</artifactId> + <version>1.4.01</version> +</dependency> + </dependencies> diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalField.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalField.java index 850b39b..a191fc9 100644 --- a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalField.java +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalField.java @@ -35,7 +35,7 @@ import com.fasterxml.jackson.annotation.JsonPropertyOrder; "value" }) public class AdditionalField { - + @JsonProperty("name") private String name; @JsonProperty("value") diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalInformation.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalInformation.java new file mode 100644 index 0000000..91173f4 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalInformation.java @@ -0,0 +1,100 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "name", + "value" +}) +public class AdditionalInformation { + + @JsonProperty("name") + private String name; + @JsonProperty("value") + private String value; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("name") + public String getName() { + return name; + } + + @JsonProperty("name") + public void setName(String name) { + this.name = name; + } + + @JsonProperty("value") + public String getValue() { + return value; + } + + @JsonProperty("value") + public void setValue(String value) { + this.value = value; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("name", name).append("value", value).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(additionalProperties).append(name).append(value).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof AdditionalInformation) == false) { + return false; + } + AdditionalInformation rhs = ((AdditionalInformation) other); + return new EqualsBuilder().append(additionalProperties, rhs.additionalProperties).append(name, rhs.name).append(value, rhs.value).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalMeasurement.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalMeasurement.java new file mode 100644 index 0000000..a82bf56 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalMeasurement.java @@ -0,0 +1,101 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "name", + "arrayOfFields" +}) +public class AdditionalMeasurement { + + @JsonProperty("name") + private String name; + @JsonProperty("arrayOfFields") + private List<ArrayOfField> arrayOfFields = null; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("name") + public String getName() { + return name; + } + + @JsonProperty("name") + public void setName(String name) { + this.name = name; + } + + @JsonProperty("arrayOfFields") + public List<ArrayOfField> getArrayOfFields() { + return arrayOfFields; + } + + @JsonProperty("arrayOfFields") + public void setArrayOfFields(List<ArrayOfField> arrayOfFields) { + this.arrayOfFields = arrayOfFields; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("name", name).append("arrayOfFields", arrayOfFields).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(arrayOfFields).append(additionalProperties).append(name).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof AdditionalMeasurement) == false) { + return false; + } + AdditionalMeasurement rhs = ((AdditionalMeasurement) other); + return new EqualsBuilder().append(arrayOfFields, rhs.arrayOfFields).append(additionalProperties, rhs.additionalProperties).append(name, rhs.name).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalObject.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalObject.java new file mode 100644 index 0000000..b2e2e1f --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalObject.java @@ -0,0 +1,153 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "objectInstances", + "objectName", + "objectSchema", + "objectSchemaUrl", + "nfSubscribedObjectName", + "nfSubscriptionId" +}) +public class AdditionalObject { + + @JsonProperty("objectInstances") + private List<ObjectInstance> objectInstances = null; + @JsonProperty("objectName") + private String objectName; + @JsonProperty("objectSchema") + private String objectSchema; + @JsonProperty("objectSchemaUrl") + private String objectSchemaUrl; + @JsonProperty("nfSubscribedObjectName") + private String nfSubscribedObjectName; + @JsonProperty("nfSubscriptionId") + private String nfSubscriptionId; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("objectInstances") + public List<ObjectInstance> getObjectInstances() { + return objectInstances; + } + + @JsonProperty("objectInstances") + public void setObjectInstances(List<ObjectInstance> objectInstances) { + this.objectInstances = objectInstances; + } + + @JsonProperty("objectName") + public String getObjectName() { + return objectName; + } + + @JsonProperty("objectName") + public void setObjectName(String objectName) { + this.objectName = objectName; + } + + @JsonProperty("objectSchema") + public String getObjectSchema() { + return objectSchema; + } + + @JsonProperty("objectSchema") + public void setObjectSchema(String objectSchema) { + this.objectSchema = objectSchema; + } + + @JsonProperty("objectSchemaUrl") + public String getObjectSchemaUrl() { + return objectSchemaUrl; + } + + @JsonProperty("objectSchemaUrl") + public void setObjectSchemaUrl(String objectSchemaUrl) { + this.objectSchemaUrl = objectSchemaUrl; + } + + @JsonProperty("nfSubscribedObjectName") + public String getNfSubscribedObjectName() { + return nfSubscribedObjectName; + } + + @JsonProperty("nfSubscribedObjectName") + public void setNfSubscribedObjectName(String nfSubscribedObjectName) { + this.nfSubscribedObjectName = nfSubscribedObjectName; + } + + @JsonProperty("nfSubscriptionId") + public String getNfSubscriptionId() { + return nfSubscriptionId; + } + + @JsonProperty("nfSubscriptionId") + public void setNfSubscriptionId(String nfSubscriptionId) { + this.nfSubscriptionId = nfSubscriptionId; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("objectInstances", objectInstances).append("objectName", objectName).append("objectSchema", objectSchema).append("objectSchemaUrl", objectSchemaUrl).append("nfSubscribedObjectName", nfSubscribedObjectName).append("nfSubscriptionId", nfSubscriptionId).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(nfSubscribedObjectName).append(nfSubscriptionId).append(objectName).append(additionalProperties).append(objectInstances).append(objectSchemaUrl).append(objectSchema).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof AdditionalObject) == false) { + return false; + } + AdditionalObject rhs = ((AdditionalObject) other); + return new EqualsBuilder().append(nfSubscribedObjectName, rhs.nfSubscribedObjectName).append(nfSubscriptionId, rhs.nfSubscriptionId).append(objectName, rhs.objectName).append(additionalProperties, rhs.additionalProperties).append(objectInstances, rhs.objectInstances).append(objectSchemaUrl, rhs.objectSchemaUrl).append(objectSchema, rhs.objectSchema).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalParameter.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalParameter.java new file mode 100644 index 0000000..43bd6a9 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/AdditionalParameter.java @@ -0,0 +1,126 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "criticality", + "name", + "thresholdCrossed", + "value" +}) +public class AdditionalParameter { + + @JsonProperty("criticality") + private String criticality; + @JsonProperty("name") + private String name; + @JsonProperty("thresholdCrossed") + private String thresholdCrossed; + @JsonProperty("value") + private String value; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("criticality") + public String getCriticality() { + return criticality; + } + + @JsonProperty("criticality") + public void setCriticality(String criticality) { + this.criticality = criticality; + } + + @JsonProperty("name") + public String getName() { + return name; + } + + @JsonProperty("name") + public void setName(String name) { + this.name = name; + } + + @JsonProperty("thresholdCrossed") + public String getThresholdCrossed() { + return thresholdCrossed; + } + + @JsonProperty("thresholdCrossed") + public void setThresholdCrossed(String thresholdCrossed) { + this.thresholdCrossed = thresholdCrossed; + } + + @JsonProperty("value") + public String getValue() { + return value; + } + + @JsonProperty("value") + public void setValue(String value) { + this.value = value; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("criticality", criticality).append("name", name).append("thresholdCrossed", thresholdCrossed).append("value", value).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(criticality).append(additionalProperties).append(name).append(value).append(thresholdCrossed).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof AdditionalParameter) == false) { + return false; + } + AdditionalParameter rhs = ((AdditionalParameter) other); + return new EqualsBuilder().append(criticality, rhs.criticality).append(additionalProperties, rhs.additionalProperties).append(name, rhs.name).append(value, rhs.value).append(thresholdCrossed, rhs.thresholdCrossed).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ArrayOfField.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ArrayOfField.java new file mode 100644 index 0000000..43b16ff --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ArrayOfField.java @@ -0,0 +1,100 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "name", + "value" +}) +public class ArrayOfField { + + @JsonProperty("name") + private String name; + @JsonProperty("value") + private String value; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("name") + public String getName() { + return name; + } + + @JsonProperty("name") + public void setName(String name) { + this.name = name; + } + + @JsonProperty("value") + public String getValue() { + return value; + } + + @JsonProperty("value") + public void setValue(String value) { + this.value = value; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("name", name).append("value", value).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(additionalProperties).append(name).append(value).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof ArrayOfField) == false) { + return false; + } + ArrayOfField rhs = ((ArrayOfField) other); + return new EqualsBuilder().append(additionalProperties, rhs.additionalProperties).append(name, rhs.name).append(value, rhs.value).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/CodecUsageArray.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/CodecUsageArray.java new file mode 100644 index 0000000..ea581ff --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/CodecUsageArray.java @@ -0,0 +1,100 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "codecIdentifier", + "numberInUse" +}) +public class CodecUsageArray { + + @JsonProperty("codecIdentifier") + private String codecIdentifier; + @JsonProperty("numberInUse") + private Long numberInUse; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("codecIdentifier") + public String getCodecIdentifier() { + return codecIdentifier; + } + + @JsonProperty("codecIdentifier") + public void setCodecIdentifier(String codecIdentifier) { + this.codecIdentifier = codecIdentifier; + } + + @JsonProperty("numberInUse") + public Long getNumberInUse() { + return numberInUse; + } + + @JsonProperty("numberInUse") + public void setNumberInUse(Long numberInUse) { + this.numberInUse = numberInUse; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("codecIdentifier", codecIdentifier).append("numberInUse", numberInUse).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(numberInUse).append(additionalProperties).append(codecIdentifier).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof CodecUsageArray) == false) { + return false; + } + CodecUsageArray rhs = ((CodecUsageArray) other); + return new EqualsBuilder().append(numberInUse, rhs.numberInUse).append(additionalProperties, rhs.additionalProperties).append(codecIdentifier, rhs.codecIdentifier).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/CpuUsageArray.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/CpuUsageArray.java new file mode 100644 index 0000000..eaec232 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/CpuUsageArray.java @@ -0,0 +1,204 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "cpuIdentifier", + "percentUsage", + "cpuIdle", + "cpuUsageInterrupt", + "cpuUsageNice", + "cpuUsageSoftIrq", + "cpuUsageSteal", + "cpuUsageSystem", + "cpuUsageUser", + "cpuWait" +}) +public class CpuUsageArray { + + @JsonProperty("cpuIdentifier") + private String cpuIdentifier; + @JsonProperty("percentUsage") + private Double percentUsage; + @JsonProperty("cpuIdle") + private Double cpuIdle; + @JsonProperty("cpuUsageInterrupt") + private Double cpuUsageInterrupt; + @JsonProperty("cpuUsageNice") + private Double cpuUsageNice; + @JsonProperty("cpuUsageSoftIrq") + private Double cpuUsageSoftIrq; + @JsonProperty("cpuUsageSteal") + private Double cpuUsageSteal; + @JsonProperty("cpuUsageSystem") + private Double cpuUsageSystem; + @JsonProperty("cpuUsageUser") + private Double cpuUsageUser; + @JsonProperty("cpuWait") + private Double cpuWait; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("cpuIdentifier") + public String getCpuIdentifier() { + return cpuIdentifier; + } + + @JsonProperty("cpuIdentifier") + public void setCpuIdentifier(String cpuIdentifier) { + this.cpuIdentifier = cpuIdentifier; + } + + @JsonProperty("percentUsage") + public Double getPercentUsage() { + return percentUsage; + } + + @JsonProperty("percentUsage") + public void setPercentUsage(Double percentUsage) { + this.percentUsage = percentUsage; + } + + @JsonProperty("cpuIdle") + public Double getCpuIdle() { + return cpuIdle; + } + + @JsonProperty("cpuIdle") + public void setCpuIdle(Double cpuIdle) { + this.cpuIdle = cpuIdle; + } + + @JsonProperty("cpuUsageInterrupt") + public Double getCpuUsageInterrupt() { + return cpuUsageInterrupt; + } + + @JsonProperty("cpuUsageInterrupt") + public void setCpuUsageInterrupt(Double cpuUsageInterrupt) { + this.cpuUsageInterrupt = cpuUsageInterrupt; + } + + @JsonProperty("cpuUsageNice") + public Double getCpuUsageNice() { + return cpuUsageNice; + } + + @JsonProperty("cpuUsageNice") + public void setCpuUsageNice(Double cpuUsageNice) { + this.cpuUsageNice = cpuUsageNice; + } + + @JsonProperty("cpuUsageSoftIrq") + public Double getCpuUsageSoftIrq() { + return cpuUsageSoftIrq; + } + + @JsonProperty("cpuUsageSoftIrq") + public void setCpuUsageSoftIrq(Double cpuUsageSoftIrq) { + this.cpuUsageSoftIrq = cpuUsageSoftIrq; + } + + @JsonProperty("cpuUsageSteal") + public Double getCpuUsageSteal() { + return cpuUsageSteal; + } + + @JsonProperty("cpuUsageSteal") + public void setCpuUsageSteal(Double cpuUsageSteal) { + this.cpuUsageSteal = cpuUsageSteal; + } + + @JsonProperty("cpuUsageSystem") + public Double getCpuUsageSystem() { + return cpuUsageSystem; + } + + @JsonProperty("cpuUsageSystem") + public void setCpuUsageSystem(Double cpuUsageSystem) { + this.cpuUsageSystem = cpuUsageSystem; + } + + @JsonProperty("cpuUsageUser") + public Double getCpuUsageUser() { + return cpuUsageUser; + } + + @JsonProperty("cpuUsageUser") + public void setCpuUsageUser(Double cpuUsageUser) { + this.cpuUsageUser = cpuUsageUser; + } + + @JsonProperty("cpuWait") + public Double getCpuWait() { + return cpuWait; + } + + @JsonProperty("cpuWait") + public void setCpuWait(Double cpuWait) { + this.cpuWait = cpuWait; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("cpuIdentifier", cpuIdentifier).append("percentUsage", percentUsage).append("cpuIdle", cpuIdle).append("cpuUsageInterrupt", cpuUsageInterrupt).append("cpuUsageNice", cpuUsageNice).append("cpuUsageSoftIrq", cpuUsageSoftIrq).append("cpuUsageSteal", cpuUsageSteal).append("cpuUsageSystem", cpuUsageSystem).append("cpuUsageUser", cpuUsageUser).append("cpuWait", cpuWait).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(cpuUsageNice).append(cpuUsageSteal).append(cpuUsageInterrupt).append(cpuUsageSoftIrq).append(cpuIdentifier).append(additionalProperties).append(cpuWait).append(cpuUsageSystem).append(cpuUsageUser).append(cpuIdle).append(percentUsage).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof CpuUsageArray) == false) { + return false; + } + CpuUsageArray rhs = ((CpuUsageArray) other); + return new EqualsBuilder().append(cpuUsageNice, rhs.cpuUsageNice).append(cpuUsageSteal, rhs.cpuUsageSteal).append(cpuUsageInterrupt, rhs.cpuUsageInterrupt).append(cpuUsageSoftIrq, rhs.cpuUsageSoftIrq).append(cpuIdentifier, rhs.cpuIdentifier).append(additionalProperties, rhs.additionalProperties).append(cpuWait, rhs.cpuWait).append(cpuUsageSystem, rhs.cpuUsageSystem).append(cpuUsageUser, rhs.cpuUsageUser).append(cpuIdle, rhs.cpuIdle).append(percentUsage, rhs.percentUsage).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/DiskUsageArray.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/DiskUsageArray.java new file mode 100644 index 0000000..8aafa0c --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/DiskUsageArray.java @@ -0,0 +1,607 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "diskIdentifier", + "diskIoTimeAvg", + "diskIoTimeLast", + "diskIoTimeMax", + "diskIoTimeMin", + "diskMergedReadAvg", + "diskMergedReadLast", + "diskMergedReadMax", + "diskMergedReadMin", + "diskMergedWriteAvg", + "diskMergedWriteLast", + "diskMergedWriteMax", + "diskMergedWriteMin", + "diskOctetsReadAvg", + "diskOctetsReadLast", + "diskOctetsReadMax", + "diskOctetsReadMin", + "diskOctetsWriteAvg", + "diskOctetsWriteLast", + "diskOctetsWriteMax", + "diskOctetsWriteMin", + "diskOpsReadAvg", + "diskOpsReadLast", + "diskOpsReadMax", + "diskOpsReadMin", + "diskOpsWriteAvg", + "diskOpsWriteLast", + "diskOpsWriteMax", + "diskOpsWriteMin", + "diskPendingOperationsAvg", + "diskPendingOperationsLast", + "diskPendingOperationsMax", + "diskPendingOperationsMin", + "diskTimeReadAvg", + "diskTimeReadLast", + "diskTimeReadMax", + "diskTimeReadMin", + "diskTimeWriteAvg", + "diskTimeWriteLast", + "diskTimeWriteMax", + "diskTimeWriteMin" +}) +public class DiskUsageArray { + + @JsonProperty("diskIdentifier") + private String diskIdentifier; + @JsonProperty("diskIoTimeAvg") + private Double diskIoTimeAvg; + @JsonProperty("diskIoTimeLast") + private Double diskIoTimeLast; + @JsonProperty("diskIoTimeMax") + private Double diskIoTimeMax; + @JsonProperty("diskIoTimeMin") + private Double diskIoTimeMin; + @JsonProperty("diskMergedReadAvg") + private Double diskMergedReadAvg; + @JsonProperty("diskMergedReadLast") + private Double diskMergedReadLast; + @JsonProperty("diskMergedReadMax") + private Double diskMergedReadMax; + @JsonProperty("diskMergedReadMin") + private Double diskMergedReadMin; + @JsonProperty("diskMergedWriteAvg") + private Double diskMergedWriteAvg; + @JsonProperty("diskMergedWriteLast") + private Double diskMergedWriteLast; + @JsonProperty("diskMergedWriteMax") + private Double diskMergedWriteMax; + @JsonProperty("diskMergedWriteMin") + private Double diskMergedWriteMin; + @JsonProperty("diskOctetsReadAvg") + private Double diskOctetsReadAvg; + @JsonProperty("diskOctetsReadLast") + private Double diskOctetsReadLast; + @JsonProperty("diskOctetsReadMax") + private Double diskOctetsReadMax; + @JsonProperty("diskOctetsReadMin") + private Double diskOctetsReadMin; + @JsonProperty("diskOctetsWriteAvg") + private Double diskOctetsWriteAvg; + @JsonProperty("diskOctetsWriteLast") + private Double diskOctetsWriteLast; + @JsonProperty("diskOctetsWriteMax") + private Double diskOctetsWriteMax; + @JsonProperty("diskOctetsWriteMin") + private Double diskOctetsWriteMin; + @JsonProperty("diskOpsReadAvg") + private Double diskOpsReadAvg; + @JsonProperty("diskOpsReadLast") + private Double diskOpsReadLast; + @JsonProperty("diskOpsReadMax") + private Double diskOpsReadMax; + @JsonProperty("diskOpsReadMin") + private Double diskOpsReadMin; + @JsonProperty("diskOpsWriteAvg") + private Double diskOpsWriteAvg; + @JsonProperty("diskOpsWriteLast") + private Double diskOpsWriteLast; + @JsonProperty("diskOpsWriteMax") + private Double diskOpsWriteMax; + @JsonProperty("diskOpsWriteMin") + private Double diskOpsWriteMin; + @JsonProperty("diskPendingOperationsAvg") + private Double diskPendingOperationsAvg; + @JsonProperty("diskPendingOperationsLast") + private Double diskPendingOperationsLast; + @JsonProperty("diskPendingOperationsMax") + private Double diskPendingOperationsMax; + @JsonProperty("diskPendingOperationsMin") + private Double diskPendingOperationsMin; + @JsonProperty("diskTimeReadAvg") + private Double diskTimeReadAvg; + @JsonProperty("diskTimeReadLast") + private Double diskTimeReadLast; + @JsonProperty("diskTimeReadMax") + private Double diskTimeReadMax; + @JsonProperty("diskTimeReadMin") + private Double diskTimeReadMin; + @JsonProperty("diskTimeWriteAvg") + private Double diskTimeWriteAvg; + @JsonProperty("diskTimeWriteLast") + private Double diskTimeWriteLast; + @JsonProperty("diskTimeWriteMax") + private Double diskTimeWriteMax; + @JsonProperty("diskTimeWriteMin") + private Double diskTimeWriteMin; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("diskIdentifier") + public String getDiskIdentifier() { + return diskIdentifier; + } + + @JsonProperty("diskIdentifier") + public void setDiskIdentifier(String diskIdentifier) { + this.diskIdentifier = diskIdentifier; + } + + @JsonProperty("diskIoTimeAvg") + public Double getDiskIoTimeAvg() { + return diskIoTimeAvg; + } + + @JsonProperty("diskIoTimeAvg") + public void setDiskIoTimeAvg(Double diskIoTimeAvg) { + this.diskIoTimeAvg = diskIoTimeAvg; + } + + @JsonProperty("diskIoTimeLast") + public Double getDiskIoTimeLast() { + return diskIoTimeLast; + } + + @JsonProperty("diskIoTimeLast") + public void setDiskIoTimeLast(Double diskIoTimeLast) { + this.diskIoTimeLast = diskIoTimeLast; + } + + @JsonProperty("diskIoTimeMax") + public Double getDiskIoTimeMax() { + return diskIoTimeMax; + } + + @JsonProperty("diskIoTimeMax") + public void setDiskIoTimeMax(Double diskIoTimeMax) { + this.diskIoTimeMax = diskIoTimeMax; + } + + @JsonProperty("diskIoTimeMin") + public Double getDiskIoTimeMin() { + return diskIoTimeMin; + } + + @JsonProperty("diskIoTimeMin") + public void setDiskIoTimeMin(Double diskIoTimeMin) { + this.diskIoTimeMin = diskIoTimeMin; + } + + @JsonProperty("diskMergedReadAvg") + public Double getDiskMergedReadAvg() { + return diskMergedReadAvg; + } + + @JsonProperty("diskMergedReadAvg") + public void setDiskMergedReadAvg(Double diskMergedReadAvg) { + this.diskMergedReadAvg = diskMergedReadAvg; + } + + @JsonProperty("diskMergedReadLast") + public Double getDiskMergedReadLast() { + return diskMergedReadLast; + } + + @JsonProperty("diskMergedReadLast") + public void setDiskMergedReadLast(Double diskMergedReadLast) { + this.diskMergedReadLast = diskMergedReadLast; + } + + @JsonProperty("diskMergedReadMax") + public Double getDiskMergedReadMax() { + return diskMergedReadMax; + } + + @JsonProperty("diskMergedReadMax") + public void setDiskMergedReadMax(Double diskMergedReadMax) { + this.diskMergedReadMax = diskMergedReadMax; + } + + @JsonProperty("diskMergedReadMin") + public Double getDiskMergedReadMin() { + return diskMergedReadMin; + } + + @JsonProperty("diskMergedReadMin") + public void setDiskMergedReadMin(Double diskMergedReadMin) { + this.diskMergedReadMin = diskMergedReadMin; + } + + @JsonProperty("diskMergedWriteAvg") + public Double getDiskMergedWriteAvg() { + return diskMergedWriteAvg; + } + + @JsonProperty("diskMergedWriteAvg") + public void setDiskMergedWriteAvg(Double diskMergedWriteAvg) { + this.diskMergedWriteAvg = diskMergedWriteAvg; + } + + @JsonProperty("diskMergedWriteLast") + public Double getDiskMergedWriteLast() { + return diskMergedWriteLast; + } + + @JsonProperty("diskMergedWriteLast") + public void setDiskMergedWriteLast(Double diskMergedWriteLast) { + this.diskMergedWriteLast = diskMergedWriteLast; + } + + @JsonProperty("diskMergedWriteMax") + public Double getDiskMergedWriteMax() { + return diskMergedWriteMax; + } + + @JsonProperty("diskMergedWriteMax") + public void setDiskMergedWriteMax(Double diskMergedWriteMax) { + this.diskMergedWriteMax = diskMergedWriteMax; + } + + @JsonProperty("diskMergedWriteMin") + public Double getDiskMergedWriteMin() { + return diskMergedWriteMin; + } + + @JsonProperty("diskMergedWriteMin") + public void setDiskMergedWriteMin(Double diskMergedWriteMin) { + this.diskMergedWriteMin = diskMergedWriteMin; + } + + @JsonProperty("diskOctetsReadAvg") + public Double getDiskOctetsReadAvg() { + return diskOctetsReadAvg; + } + + @JsonProperty("diskOctetsReadAvg") + public void setDiskOctetsReadAvg(Double diskOctetsReadAvg) { + this.diskOctetsReadAvg = diskOctetsReadAvg; + } + + @JsonProperty("diskOctetsReadLast") + public Double getDiskOctetsReadLast() { + return diskOctetsReadLast; + } + + @JsonProperty("diskOctetsReadLast") + public void setDiskOctetsReadLast(Double diskOctetsReadLast) { + this.diskOctetsReadLast = diskOctetsReadLast; + } + + @JsonProperty("diskOctetsReadMax") + public Double getDiskOctetsReadMax() { + return diskOctetsReadMax; + } + + @JsonProperty("diskOctetsReadMax") + public void setDiskOctetsReadMax(Double diskOctetsReadMax) { + this.diskOctetsReadMax = diskOctetsReadMax; + } + + @JsonProperty("diskOctetsReadMin") + public Double getDiskOctetsReadMin() { + return diskOctetsReadMin; + } + + @JsonProperty("diskOctetsReadMin") + public void setDiskOctetsReadMin(Double diskOctetsReadMin) { + this.diskOctetsReadMin = diskOctetsReadMin; + } + + @JsonProperty("diskOctetsWriteAvg") + public Double getDiskOctetsWriteAvg() { + return diskOctetsWriteAvg; + } + + @JsonProperty("diskOctetsWriteAvg") + public void setDiskOctetsWriteAvg(Double diskOctetsWriteAvg) { + this.diskOctetsWriteAvg = diskOctetsWriteAvg; + } + + @JsonProperty("diskOctetsWriteLast") + public Double getDiskOctetsWriteLast() { + return diskOctetsWriteLast; + } + + @JsonProperty("diskOctetsWriteLast") + public void setDiskOctetsWriteLast(Double diskOctetsWriteLast) { + this.diskOctetsWriteLast = diskOctetsWriteLast; + } + + @JsonProperty("diskOctetsWriteMax") + public Double getDiskOctetsWriteMax() { + return diskOctetsWriteMax; + } + + @JsonProperty("diskOctetsWriteMax") + public void setDiskOctetsWriteMax(Double diskOctetsWriteMax) { + this.diskOctetsWriteMax = diskOctetsWriteMax; + } + + @JsonProperty("diskOctetsWriteMin") + public Double getDiskOctetsWriteMin() { + return diskOctetsWriteMin; + } + + @JsonProperty("diskOctetsWriteMin") + public void setDiskOctetsWriteMin(Double diskOctetsWriteMin) { + this.diskOctetsWriteMin = diskOctetsWriteMin; + } + + @JsonProperty("diskOpsReadAvg") + public Double getDiskOpsReadAvg() { + return diskOpsReadAvg; + } + + @JsonProperty("diskOpsReadAvg") + public void setDiskOpsReadAvg(Double diskOpsReadAvg) { + this.diskOpsReadAvg = diskOpsReadAvg; + } + + @JsonProperty("diskOpsReadLast") + public Double getDiskOpsReadLast() { + return diskOpsReadLast; + } + + @JsonProperty("diskOpsReadLast") + public void setDiskOpsReadLast(Double diskOpsReadLast) { + this.diskOpsReadLast = diskOpsReadLast; + } + + @JsonProperty("diskOpsReadMax") + public Double getDiskOpsReadMax() { + return diskOpsReadMax; + } + + @JsonProperty("diskOpsReadMax") + public void setDiskOpsReadMax(Double diskOpsReadMax) { + this.diskOpsReadMax = diskOpsReadMax; + } + + @JsonProperty("diskOpsReadMin") + public Double getDiskOpsReadMin() { + return diskOpsReadMin; + } + + @JsonProperty("diskOpsReadMin") + public void setDiskOpsReadMin(Double diskOpsReadMin) { + this.diskOpsReadMin = diskOpsReadMin; + } + + @JsonProperty("diskOpsWriteAvg") + public Double getDiskOpsWriteAvg() { + return diskOpsWriteAvg; + } + + @JsonProperty("diskOpsWriteAvg") + public void setDiskOpsWriteAvg(Double diskOpsWriteAvg) { + this.diskOpsWriteAvg = diskOpsWriteAvg; + } + + @JsonProperty("diskOpsWriteLast") + public Double getDiskOpsWriteLast() { + return diskOpsWriteLast; + } + + @JsonProperty("diskOpsWriteLast") + public void setDiskOpsWriteLast(Double diskOpsWriteLast) { + this.diskOpsWriteLast = diskOpsWriteLast; + } + + @JsonProperty("diskOpsWriteMax") + public Double getDiskOpsWriteMax() { + return diskOpsWriteMax; + } + + @JsonProperty("diskOpsWriteMax") + public void setDiskOpsWriteMax(Double diskOpsWriteMax) { + this.diskOpsWriteMax = diskOpsWriteMax; + } + + @JsonProperty("diskOpsWriteMin") + public Double getDiskOpsWriteMin() { + return diskOpsWriteMin; + } + + @JsonProperty("diskOpsWriteMin") + public void setDiskOpsWriteMin(Double diskOpsWriteMin) { + this.diskOpsWriteMin = diskOpsWriteMin; + } + + @JsonProperty("diskPendingOperationsAvg") + public Double getDiskPendingOperationsAvg() { + return diskPendingOperationsAvg; + } + + @JsonProperty("diskPendingOperationsAvg") + public void setDiskPendingOperationsAvg(Double diskPendingOperationsAvg) { + this.diskPendingOperationsAvg = diskPendingOperationsAvg; + } + + @JsonProperty("diskPendingOperationsLast") + public Double getDiskPendingOperationsLast() { + return diskPendingOperationsLast; + } + + @JsonProperty("diskPendingOperationsLast") + public void setDiskPendingOperationsLast(Double diskPendingOperationsLast) { + this.diskPendingOperationsLast = diskPendingOperationsLast; + } + + @JsonProperty("diskPendingOperationsMax") + public Double getDiskPendingOperationsMax() { + return diskPendingOperationsMax; + } + + @JsonProperty("diskPendingOperationsMax") + public void setDiskPendingOperationsMax(Double diskPendingOperationsMax) { + this.diskPendingOperationsMax = diskPendingOperationsMax; + } + + @JsonProperty("diskPendingOperationsMin") + public Double getDiskPendingOperationsMin() { + return diskPendingOperationsMin; + } + + @JsonProperty("diskPendingOperationsMin") + public void setDiskPendingOperationsMin(Double diskPendingOperationsMin) { + this.diskPendingOperationsMin = diskPendingOperationsMin; + } + + @JsonProperty("diskTimeReadAvg") + public Double getDiskTimeReadAvg() { + return diskTimeReadAvg; + } + + @JsonProperty("diskTimeReadAvg") + public void setDiskTimeReadAvg(Double diskTimeReadAvg) { + this.diskTimeReadAvg = diskTimeReadAvg; + } + + @JsonProperty("diskTimeReadLast") + public Double getDiskTimeReadLast() { + return diskTimeReadLast; + } + + @JsonProperty("diskTimeReadLast") + public void setDiskTimeReadLast(Double diskTimeReadLast) { + this.diskTimeReadLast = diskTimeReadLast; + } + + @JsonProperty("diskTimeReadMax") + public Double getDiskTimeReadMax() { + return diskTimeReadMax; + } + + @JsonProperty("diskTimeReadMax") + public void setDiskTimeReadMax(Double diskTimeReadMax) { + this.diskTimeReadMax = diskTimeReadMax; + } + + @JsonProperty("diskTimeReadMin") + public Double getDiskTimeReadMin() { + return diskTimeReadMin; + } + + @JsonProperty("diskTimeReadMin") + public void setDiskTimeReadMin(Double diskTimeReadMin) { + this.diskTimeReadMin = diskTimeReadMin; + } + + @JsonProperty("diskTimeWriteAvg") + public Double getDiskTimeWriteAvg() { + return diskTimeWriteAvg; + } + + @JsonProperty("diskTimeWriteAvg") + public void setDiskTimeWriteAvg(Double diskTimeWriteAvg) { + this.diskTimeWriteAvg = diskTimeWriteAvg; + } + + @JsonProperty("diskTimeWriteLast") + public Double getDiskTimeWriteLast() { + return diskTimeWriteLast; + } + + @JsonProperty("diskTimeWriteLast") + public void setDiskTimeWriteLast(Double diskTimeWriteLast) { + this.diskTimeWriteLast = diskTimeWriteLast; + } + + @JsonProperty("diskTimeWriteMax") + public Double getDiskTimeWriteMax() { + return diskTimeWriteMax; + } + + @JsonProperty("diskTimeWriteMax") + public void setDiskTimeWriteMax(Double diskTimeWriteMax) { + this.diskTimeWriteMax = diskTimeWriteMax; + } + + @JsonProperty("diskTimeWriteMin") + public Double getDiskTimeWriteMin() { + return diskTimeWriteMin; + } + + @JsonProperty("diskTimeWriteMin") + public void setDiskTimeWriteMin(Double diskTimeWriteMin) { + this.diskTimeWriteMin = diskTimeWriteMin; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("diskIdentifier", diskIdentifier).append("diskIoTimeAvg", diskIoTimeAvg).append("diskIoTimeLast", diskIoTimeLast).append("diskIoTimeMax", diskIoTimeMax).append("diskIoTimeMin", diskIoTimeMin).append("diskMergedReadAvg", diskMergedReadAvg).append("diskMergedReadLast", diskMergedReadLast).append("diskMergedReadMax", diskMergedReadMax).append("diskMergedReadMin", diskMergedReadMin).append("diskMergedWriteAvg", diskMergedWriteAvg).append("diskMergedWriteLast", diskMergedWriteLast).append("diskMergedWriteMax", diskMergedWriteMax).append("diskMergedWriteMin", diskMergedWriteMin).append("diskOctetsReadAvg", diskOctetsReadAvg).append("diskOctetsReadLast", diskOctetsReadLast).append("diskOctetsReadMax", diskOctetsReadMax).append("diskOctetsReadMin", diskOctetsReadMin).append("diskOctetsWriteAvg", diskOctetsWriteAvg).append("diskOctetsWriteLast", diskOctetsWriteLast).append("diskOctetsWriteMax", diskOctetsWriteMax).append("diskOctetsWriteMin", diskOctetsWriteMin).append("diskOpsReadAvg", diskOpsReadAvg).append("diskOpsReadLast", diskOpsReadLast).append("diskOpsReadMax", diskOpsReadMax).append("diskOpsReadMin", diskOpsReadMin).append("diskOpsWriteAvg", diskOpsWriteAvg).append("diskOpsWriteLast", diskOpsWriteLast).append("diskOpsWriteMax", diskOpsWriteMax).append("diskOpsWriteMin", diskOpsWriteMin).append("diskPendingOperationsAvg", diskPendingOperationsAvg).append("diskPendingOperationsLast", diskPendingOperationsLast).append("diskPendingOperationsMax", diskPendingOperationsMax).append("diskPendingOperationsMin", diskPendingOperationsMin).append("diskTimeReadAvg", diskTimeReadAvg).append("diskTimeReadLast", diskTimeReadLast).append("diskTimeReadMax", diskTimeReadMax).append("diskTimeReadMin", diskTimeReadMin).append("diskTimeWriteAvg", diskTimeWriteAvg).append("diskTimeWriteLast", diskTimeWriteLast).append("diskTimeWriteMax", diskTimeWriteMax).append("diskTimeWriteMin", diskTimeWriteMin).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(diskIoTimeLast).append(diskMergedReadMin).append(diskMergedReadLast).append(diskTimeWriteAvg).append(diskIoTimeAvg).append(diskOpsReadLast).append(diskOctetsWriteAvg).append(diskOctetsReadMin).append(diskTimeWriteLast).append(diskOpsWriteMin).append(diskOpsWriteAvg).append(diskTimeWriteMax).append(diskTimeReadMax).append(diskOctetsWriteMin).append(diskMergedWriteAvg).append(diskTimeWriteMin).append(diskTimeReadAvg).append(diskMergedWriteMax).append(diskMergedReadAvg).append(diskPendingOperationsMax).append(diskIdentifier).append(diskPendingOperationsMin).append(diskTimeReadLast).append(diskOpsReadAvg).append(diskMergedWriteMin).append(diskIoTimeMax).append(diskPendingOperationsAvg).append(diskMergedWriteLast).append(diskMergedReadMax).append(diskIoTimeMin).append(diskTimeReadMin).append(diskPendingOperationsLast).append(diskOpsReadMin).append(diskOctetsReadLast).append(diskOctetsReadAvg).append(diskOpsWriteMax).append(additionalProperties).append(diskOctetsReadMax).append(diskOctetsWriteMax).append(diskOctetsWriteLast).append(diskOpsWriteLast).append(diskOpsReadMax).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof DiskUsageArray) == false) { + return false; + } + DiskUsageArray rhs = ((DiskUsageArray) other); + return new EqualsBuilder().append(diskIoTimeLast, rhs.diskIoTimeLast).append(diskMergedReadMin, rhs.diskMergedReadMin).append(diskMergedReadLast, rhs.diskMergedReadLast).append(diskTimeWriteAvg, rhs.diskTimeWriteAvg).append(diskIoTimeAvg, rhs.diskIoTimeAvg).append(diskOpsReadLast, rhs.diskOpsReadLast).append(diskOctetsWriteAvg, rhs.diskOctetsWriteAvg).append(diskOctetsReadMin, rhs.diskOctetsReadMin).append(diskTimeWriteLast, rhs.diskTimeWriteLast).append(diskOpsWriteMin, rhs.diskOpsWriteMin).append(diskOpsWriteAvg, rhs.diskOpsWriteAvg).append(diskTimeWriteMax, rhs.diskTimeWriteMax).append(diskTimeReadMax, rhs.diskTimeReadMax).append(diskOctetsWriteMin, rhs.diskOctetsWriteMin).append(diskMergedWriteAvg, rhs.diskMergedWriteAvg).append(diskTimeWriteMin, rhs.diskTimeWriteMin).append(diskTimeReadAvg, rhs.diskTimeReadAvg).append(diskMergedWriteMax, rhs.diskMergedWriteMax).append(diskMergedReadAvg, rhs.diskMergedReadAvg).append(diskPendingOperationsMax, rhs.diskPendingOperationsMax).append(diskIdentifier, rhs.diskIdentifier).append(diskPendingOperationsMin, rhs.diskPendingOperationsMin).append(diskTimeReadLast, rhs.diskTimeReadLast).append(diskOpsReadAvg, rhs.diskOpsReadAvg).append(diskMergedWriteMin, rhs.diskMergedWriteMin).append(diskIoTimeMax, rhs.diskIoTimeMax).append(diskPendingOperationsAvg, rhs.diskPendingOperationsAvg).append(diskMergedWriteLast, rhs.diskMergedWriteLast).append(diskMergedReadMax, rhs.diskMergedReadMax).append(diskIoTimeMin, rhs.diskIoTimeMin).append(diskTimeReadMin, rhs.diskTimeReadMin).append(diskPendingOperationsLast, rhs.diskPendingOperationsLast).append(diskOpsReadMin, rhs.diskOpsReadMin).append(diskOctetsReadLast, rhs.diskOctetsReadLast).append(diskOctetsReadAvg, rhs.diskOctetsReadAvg).append(diskOpsWriteMax, rhs.diskOpsWriteMax).append(additionalProperties, rhs.additionalProperties).append(diskOctetsReadMax, rhs.diskOctetsReadMax).append(diskOctetsWriteMax, rhs.diskOctetsWriteMax).append(diskOctetsWriteLast, rhs.diskOctetsWriteLast).append(diskOpsWriteLast, rhs.diskOpsWriteLast).append(diskOpsReadMax, rhs.diskOpsReadMax).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/EndOfCallVqmSummaries.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/EndOfCallVqmSummaries.java new file mode 100644 index 0000000..01a2a80 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/EndOfCallVqmSummaries.java @@ -0,0 +1,347 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "adjacencyName", + "endpointDescription", + "endpointJitter", + "endpointRtpOctetsDiscarded", + "endpointRtpOctetsReceived", + "endpointRtpOctetsSent", + "endpointRtpPacketsDiscarded", + "endpointRtpPacketsReceived", + "endpointRtpPacketsSent", + "localJitter", + "localRtpOctetsDiscarded", + "localRtpOctetsReceived", + "localRtpOctetsSent", + "localRtpPacketsDiscarded", + "localRtpPacketsReceived", + "localRtpPacketsSent", + "mosCqe", + "packetsLost", + "packetLossPercent", + "rFactor", + "roundTripDelay" +}) +public class EndOfCallVqmSummaries { + + @JsonProperty("adjacencyName") + private String adjacencyName; + @JsonProperty("endpointDescription") + private String endpointDescription; + @JsonProperty("endpointJitter") + private Double endpointJitter; + @JsonProperty("endpointRtpOctetsDiscarded") + private Double endpointRtpOctetsDiscarded; + @JsonProperty("endpointRtpOctetsReceived") + private Double endpointRtpOctetsReceived; + @JsonProperty("endpointRtpOctetsSent") + private Double endpointRtpOctetsSent; + @JsonProperty("endpointRtpPacketsDiscarded") + private Double endpointRtpPacketsDiscarded; + @JsonProperty("endpointRtpPacketsReceived") + private Double endpointRtpPacketsReceived; + @JsonProperty("endpointRtpPacketsSent") + private Double endpointRtpPacketsSent; + @JsonProperty("localJitter") + private Double localJitter; + @JsonProperty("localRtpOctetsDiscarded") + private Double localRtpOctetsDiscarded; + @JsonProperty("localRtpOctetsReceived") + private Double localRtpOctetsReceived; + @JsonProperty("localRtpOctetsSent") + private Double localRtpOctetsSent; + @JsonProperty("localRtpPacketsDiscarded") + private Double localRtpPacketsDiscarded; + @JsonProperty("localRtpPacketsReceived") + private Double localRtpPacketsReceived; + @JsonProperty("localRtpPacketsSent") + private Double localRtpPacketsSent; + @JsonProperty("mosCqe") + private Double mosCqe; + @JsonProperty("packetsLost") + private Double packetsLost; + @JsonProperty("packetLossPercent") + private Double packetLossPercent; + @JsonProperty("rFactor") + private Double rFactor; + @JsonProperty("roundTripDelay") + private Double roundTripDelay; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("adjacencyName") + public String getAdjacencyName() { + return adjacencyName; + } + + @JsonProperty("adjacencyName") + public void setAdjacencyName(String adjacencyName) { + this.adjacencyName = adjacencyName; + } + + @JsonProperty("endpointDescription") + public String getEndpointDescription() { + return endpointDescription; + } + + @JsonProperty("endpointDescription") + public void setEndpointDescription(String endpointDescription) { + this.endpointDescription = endpointDescription; + } + + @JsonProperty("endpointJitter") + public Double getEndpointJitter() { + return endpointJitter; + } + + @JsonProperty("endpointJitter") + public void setEndpointJitter(Double endpointJitter) { + this.endpointJitter = endpointJitter; + } + + @JsonProperty("endpointRtpOctetsDiscarded") + public Double getEndpointRtpOctetsDiscarded() { + return endpointRtpOctetsDiscarded; + } + + @JsonProperty("endpointRtpOctetsDiscarded") + public void setEndpointRtpOctetsDiscarded(Double endpointRtpOctetsDiscarded) { + this.endpointRtpOctetsDiscarded = endpointRtpOctetsDiscarded; + } + + @JsonProperty("endpointRtpOctetsReceived") + public Double getEndpointRtpOctetsReceived() { + return endpointRtpOctetsReceived; + } + + @JsonProperty("endpointRtpOctetsReceived") + public void setEndpointRtpOctetsReceived(Double endpointRtpOctetsReceived) { + this.endpointRtpOctetsReceived = endpointRtpOctetsReceived; + } + + @JsonProperty("endpointRtpOctetsSent") + public Double getEndpointRtpOctetsSent() { + return endpointRtpOctetsSent; + } + + @JsonProperty("endpointRtpOctetsSent") + public void setEndpointRtpOctetsSent(Double endpointRtpOctetsSent) { + this.endpointRtpOctetsSent = endpointRtpOctetsSent; + } + + @JsonProperty("endpointRtpPacketsDiscarded") + public Double getEndpointRtpPacketsDiscarded() { + return endpointRtpPacketsDiscarded; + } + + @JsonProperty("endpointRtpPacketsDiscarded") + public void setEndpointRtpPacketsDiscarded(Double endpointRtpPacketsDiscarded) { + this.endpointRtpPacketsDiscarded = endpointRtpPacketsDiscarded; + } + + @JsonProperty("endpointRtpPacketsReceived") + public Double getEndpointRtpPacketsReceived() { + return endpointRtpPacketsReceived; + } + + @JsonProperty("endpointRtpPacketsReceived") + public void setEndpointRtpPacketsReceived(Double endpointRtpPacketsReceived) { + this.endpointRtpPacketsReceived = endpointRtpPacketsReceived; + } + + @JsonProperty("endpointRtpPacketsSent") + public Double getEndpointRtpPacketsSent() { + return endpointRtpPacketsSent; + } + + @JsonProperty("endpointRtpPacketsSent") + public void setEndpointRtpPacketsSent(Double endpointRtpPacketsSent) { + this.endpointRtpPacketsSent = endpointRtpPacketsSent; + } + + @JsonProperty("localJitter") + public Double getLocalJitter() { + return localJitter; + } + + @JsonProperty("localJitter") + public void setLocalJitter(Double localJitter) { + this.localJitter = localJitter; + } + + @JsonProperty("localRtpOctetsDiscarded") + public Double getLocalRtpOctetsDiscarded() { + return localRtpOctetsDiscarded; + } + + @JsonProperty("localRtpOctetsDiscarded") + public void setLocalRtpOctetsDiscarded(Double localRtpOctetsDiscarded) { + this.localRtpOctetsDiscarded = localRtpOctetsDiscarded; + } + + @JsonProperty("localRtpOctetsReceived") + public Double getLocalRtpOctetsReceived() { + return localRtpOctetsReceived; + } + + @JsonProperty("localRtpOctetsReceived") + public void setLocalRtpOctetsReceived(Double localRtpOctetsReceived) { + this.localRtpOctetsReceived = localRtpOctetsReceived; + } + + @JsonProperty("localRtpOctetsSent") + public Double getLocalRtpOctetsSent() { + return localRtpOctetsSent; + } + + @JsonProperty("localRtpOctetsSent") + public void setLocalRtpOctetsSent(Double localRtpOctetsSent) { + this.localRtpOctetsSent = localRtpOctetsSent; + } + + @JsonProperty("localRtpPacketsDiscarded") + public Double getLocalRtpPacketsDiscarded() { + return localRtpPacketsDiscarded; + } + + @JsonProperty("localRtpPacketsDiscarded") + public void setLocalRtpPacketsDiscarded(Double localRtpPacketsDiscarded) { + this.localRtpPacketsDiscarded = localRtpPacketsDiscarded; + } + + @JsonProperty("localRtpPacketsReceived") + public Double getLocalRtpPacketsReceived() { + return localRtpPacketsReceived; + } + + @JsonProperty("localRtpPacketsReceived") + public void setLocalRtpPacketsReceived(Double localRtpPacketsReceived) { + this.localRtpPacketsReceived = localRtpPacketsReceived; + } + + @JsonProperty("localRtpPacketsSent") + public Double getLocalRtpPacketsSent() { + return localRtpPacketsSent; + } + + @JsonProperty("localRtpPacketsSent") + public void setLocalRtpPacketsSent(Double localRtpPacketsSent) { + this.localRtpPacketsSent = localRtpPacketsSent; + } + + @JsonProperty("mosCqe") + public Double getMosCqe() { + return mosCqe; + } + + @JsonProperty("mosCqe") + public void setMosCqe(Double mosCqe) { + this.mosCqe = mosCqe; + } + + @JsonProperty("packetsLost") + public Double getPacketsLost() { + return packetsLost; + } + + @JsonProperty("packetsLost") + public void setPacketsLost(Double packetsLost) { + this.packetsLost = packetsLost; + } + + @JsonProperty("packetLossPercent") + public Double getPacketLossPercent() { + return packetLossPercent; + } + + @JsonProperty("packetLossPercent") + public void setPacketLossPercent(Double packetLossPercent) { + this.packetLossPercent = packetLossPercent; + } + + @JsonProperty("rFactor") + public Double getRFactor() { + return rFactor; + } + + @JsonProperty("rFactor") + public void setRFactor(Double rFactor) { + this.rFactor = rFactor; + } + + @JsonProperty("roundTripDelay") + public Double getRoundTripDelay() { + return roundTripDelay; + } + + @JsonProperty("roundTripDelay") + public void setRoundTripDelay(Double roundTripDelay) { + this.roundTripDelay = roundTripDelay; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("adjacencyName", adjacencyName).append("endpointDescription", endpointDescription).append("endpointJitter", endpointJitter).append("endpointRtpOctetsDiscarded", endpointRtpOctetsDiscarded).append("endpointRtpOctetsReceived", endpointRtpOctetsReceived).append("endpointRtpOctetsSent", endpointRtpOctetsSent).append("endpointRtpPacketsDiscarded", endpointRtpPacketsDiscarded).append("endpointRtpPacketsReceived", endpointRtpPacketsReceived).append("endpointRtpPacketsSent", endpointRtpPacketsSent).append("localJitter", localJitter).append("localRtpOctetsDiscarded", localRtpOctetsDiscarded).append("localRtpOctetsReceived", localRtpOctetsReceived).append("localRtpOctetsSent", localRtpOctetsSent).append("localRtpPacketsDiscarded", localRtpPacketsDiscarded).append("localRtpPacketsReceived", localRtpPacketsReceived).append("localRtpPacketsSent", localRtpPacketsSent).append("mosCqe", mosCqe).append("packetsLost", packetsLost).append("packetLossPercent", packetLossPercent).append("rFactor", rFactor).append("roundTripDelay", roundTripDelay).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(localJitter).append(adjacencyName).append(localRtpPacketsDiscarded).append(localRtpOctetsSent).append(roundTripDelay).append(localRtpPacketsReceived).append(endpointRtpPacketsReceived).append(packetLossPercent).append(endpointRtpPacketsSent).append(endpointJitter).append(mosCqe).append(endpointRtpOctetsDiscarded).append(endpointDescription).append(rFactor).append(endpointRtpPacketsDiscarded).append(localRtpOctetsReceived).append(additionalProperties).append(endpointRtpOctetsSent).append(localRtpOctetsDiscarded).append(localRtpPacketsSent).append(endpointRtpOctetsReceived).append(packetsLost).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof EndOfCallVqmSummaries) == false) { + return false; + } + EndOfCallVqmSummaries rhs = ((EndOfCallVqmSummaries) other); + return new EqualsBuilder().append(localJitter, rhs.localJitter).append(adjacencyName, rhs.adjacencyName).append(localRtpPacketsDiscarded, rhs.localRtpPacketsDiscarded).append(localRtpOctetsSent, rhs.localRtpOctetsSent).append(roundTripDelay, rhs.roundTripDelay).append(localRtpPacketsReceived, rhs.localRtpPacketsReceived).append(endpointRtpPacketsReceived, rhs.endpointRtpPacketsReceived).append(packetLossPercent, rhs.packetLossPercent).append(endpointRtpPacketsSent, rhs.endpointRtpPacketsSent).append(endpointJitter, rhs.endpointJitter).append(mosCqe, rhs.mosCqe).append(endpointRtpOctetsDiscarded, rhs.endpointRtpOctetsDiscarded).append(endpointDescription, rhs.endpointDescription).append(rFactor, rhs.rFactor).append(endpointRtpPacketsDiscarded, rhs.endpointRtpPacketsDiscarded).append(localRtpOctetsReceived, rhs.localRtpOctetsReceived).append(additionalProperties, rhs.additionalProperties).append(endpointRtpOctetsSent, rhs.endpointRtpOctetsSent).append(localRtpOctetsDiscarded, rhs.localRtpOctetsDiscarded).append(localRtpPacketsSent, rhs.localRtpPacketsSent).append(endpointRtpOctetsReceived, rhs.endpointRtpOctetsReceived).append(packetsLost, rhs.packetsLost).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/Event.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/Event.java index b83cf93..9476178 100644 --- a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/Event.java +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/Event.java @@ -21,19 +21,29 @@ package org.onap.dcaegen2.ves.domain; import java.util.HashMap; import java.util.Map; -import org.apache.commons.lang.builder.EqualsBuilder; -import org.apache.commons.lang.builder.HashCodeBuilder; -import org.apache.commons.lang.builder.ToStringBuilder; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; @JsonInclude(JsonInclude.Include.NON_NULL) @JsonPropertyOrder({ "commonEventHeader", "faultFields", - "heartbeatFields" + "heartbeatFields", + "measurementsForVfScalingFields", + "mobileFlowFields", + "otherFields", + "sipSignalingFields", + "stateChangeFields", + "syslogFields", + "thresholdCrossingAlertFields", + "voiceQualityFields" }) public class Event { @@ -43,7 +53,22 @@ public class Event { private FaultFields faultFields; @JsonProperty("heartbeatFields") private HeartbeatFields heartbeatFields; - + @JsonProperty("measurementsForVfScalingFields") + private MeasurementsForVfScalingFields measurementsForVfScalingFields; + @JsonProperty("mobileFlowFields") + private MobileFlowFields mobileFlowFields; + @JsonProperty("otherFields") + private OtherFields otherFields; + @JsonProperty("sipSignalingFields") + private SipSignalingFields sipSignalingFields; + @JsonProperty("stateChangeFields") + private StateChangeFields stateChangeFields; + @JsonProperty("syslogFields") + private SyslogFields syslogFields; + @JsonProperty("thresholdCrossingAlertFields") + private ThresholdCrossingAlertFields thresholdCrossingAlertFields; + @JsonProperty("voiceQualityFields") + private VoiceQualityFields voiceQualityFields; @JsonIgnore private Map<String, Object> additionalProperties = new HashMap<String, Object>(); @@ -77,15 +102,105 @@ public class Event { this.heartbeatFields = heartbeatFields; } - + @JsonProperty("measurementsForVfScalingFields") + public MeasurementsForVfScalingFields getMeasurementsForVfScalingFields() { + return measurementsForVfScalingFields; + } + + @JsonProperty("measurementsForVfScalingFields") + public void setMeasurementsForVfScalingFields(MeasurementsForVfScalingFields measurementsForVfScalingFields) { + this.measurementsForVfScalingFields = measurementsForVfScalingFields; + } + + @JsonProperty("mobileFlowFields") + public MobileFlowFields getMobileFlowFields() { + return mobileFlowFields; + } + + @JsonProperty("mobileFlowFields") + public void setMobileFlowFields(MobileFlowFields mobileFlowFields) { + this.mobileFlowFields = mobileFlowFields; + } + + @JsonProperty("otherFields") + public OtherFields getOtherFields() { + return otherFields; + } + + @JsonProperty("otherFields") + public void setOtherFields(OtherFields otherFields) { + this.otherFields = otherFields; + } + + @JsonProperty("sipSignalingFields") + public SipSignalingFields getSipSignalingFields() { + return sipSignalingFields; + } + + @JsonProperty("sipSignalingFields") + public void setSipSignalingFields(SipSignalingFields sipSignalingFields) { + this.sipSignalingFields = sipSignalingFields; + } + + @JsonProperty("stateChangeFields") + public StateChangeFields getStateChangeFields() { + return stateChangeFields; + } + + @JsonProperty("stateChangeFields") + public void setStateChangeFields(StateChangeFields stateChangeFields) { + this.stateChangeFields = stateChangeFields; + } + + @JsonProperty("syslogFields") + public SyslogFields getSyslogFields() { + return syslogFields; + } + + @JsonProperty("syslogFields") + public void setSyslogFields(SyslogFields syslogFields) { + this.syslogFields = syslogFields; + } + + @JsonProperty("thresholdCrossingAlertFields") + public ThresholdCrossingAlertFields getThresholdCrossingAlertFields() { + return thresholdCrossingAlertFields; + } + + @JsonProperty("thresholdCrossingAlertFields") + public void setThresholdCrossingAlertFields(ThresholdCrossingAlertFields thresholdCrossingAlertFields) { + this.thresholdCrossingAlertFields = thresholdCrossingAlertFields; + } + + @JsonProperty("voiceQualityFields") + public VoiceQualityFields getVoiceQualityFields() { + return voiceQualityFields; + } + + @JsonProperty("voiceQualityFields") + public void setVoiceQualityFields(VoiceQualityFields voiceQualityFields) { + this.voiceQualityFields = voiceQualityFields; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + @Override public String toString() { - return new ToStringBuilder(this).append("commonEventHeader", commonEventHeader).append("faultFields", faultFields).append("heartbeatFields", heartbeatFields).toString(); + return new ToStringBuilder(this).append("commonEventHeader", commonEventHeader).append("faultFields", faultFields).append("heartbeatFields", heartbeatFields).append("measurementsForVfScalingFields", measurementsForVfScalingFields).append("mobileFlowFields", mobileFlowFields).append("otherFields", otherFields).append("sipSignalingFields", sipSignalingFields).append("stateChangeFields", stateChangeFields).append("syslogFields", syslogFields).append("thresholdCrossingAlertFields", thresholdCrossingAlertFields).append("voiceQualityFields", voiceQualityFields).append("additionalProperties", additionalProperties).toString(); } @Override public int hashCode() { - return new HashCodeBuilder().append(heartbeatFields).append(commonEventHeader).append(additionalProperties).append(faultFields).toHashCode(); } + return new HashCodeBuilder().append(mobileFlowFields).append(heartbeatFields).append(measurementsForVfScalingFields).append(otherFields).append(commonEventHeader).append(thresholdCrossingAlertFields).append(syslogFields).append(additionalProperties).append(stateChangeFields).append(voiceQualityFields).append(sipSignalingFields).append(faultFields).toHashCode(); + } @Override public boolean equals(Object other) { @@ -96,7 +211,7 @@ public class Event { return false; } Event rhs = ((Event) other); - return new EqualsBuilder().append(heartbeatFields, rhs.heartbeatFields).append(commonEventHeader, rhs.commonEventHeader).append(additionalProperties, rhs.additionalProperties).append(faultFields, rhs.faultFields).isEquals(); + return new EqualsBuilder().append(mobileFlowFields, rhs.mobileFlowFields).append(heartbeatFields, rhs.heartbeatFields).append(measurementsForVfScalingFields, rhs.measurementsForVfScalingFields).append(otherFields, rhs.otherFields).append(commonEventHeader, rhs.commonEventHeader).append(thresholdCrossingAlertFields, rhs.thresholdCrossingAlertFields).append(syslogFields, rhs.syslogFields).append(additionalProperties, rhs.additionalProperties).append(stateChangeFields, rhs.stateChangeFields).append(voiceQualityFields, rhs.voiceQualityFields).append(sipSignalingFields, rhs.sipSignalingFields).append(faultFields, rhs.faultFields).isEquals(); } } diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/FeatureUsageArray.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/FeatureUsageArray.java new file mode 100644 index 0000000..ccf0614 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/FeatureUsageArray.java @@ -0,0 +1,100 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "featureIdentifier", + "featureUtilization" +}) +public class FeatureUsageArray { + + @JsonProperty("featureIdentifier") + private String featureIdentifier; + @JsonProperty("featureUtilization") + private Long featureUtilization; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("featureIdentifier") + public String getFeatureIdentifier() { + return featureIdentifier; + } + + @JsonProperty("featureIdentifier") + public void setFeatureIdentifier(String featureIdentifier) { + this.featureIdentifier = featureIdentifier; + } + + @JsonProperty("featureUtilization") + public Long getFeatureUtilization() { + return featureUtilization; + } + + @JsonProperty("featureUtilization") + public void setFeatureUtilization(Long featureUtilization) { + this.featureUtilization = featureUtilization; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("featureIdentifier", featureIdentifier).append("featureUtilization", featureUtilization).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(featureIdentifier).append(additionalProperties).append(featureUtilization).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof FeatureUsageArray) == false) { + return false; + } + FeatureUsageArray rhs = ((FeatureUsageArray) other); + return new EqualsBuilder().append(featureIdentifier, rhs.featureIdentifier).append(additionalProperties, rhs.additionalProperties).append(featureUtilization, rhs.featureUtilization).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/FilesystemUsageArray.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/FilesystemUsageArray.java new file mode 100644 index 0000000..83fa2c1 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/FilesystemUsageArray.java @@ -0,0 +1,165 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "blockConfigured", + "blockIops", + "blockUsed", + "ephemeralConfigured", + "ephemeralIops", + "ephemeralUsed", + "filesystemName" +}) +public class FilesystemUsageArray { + + @JsonProperty("blockConfigured") + private Double blockConfigured; + @JsonProperty("blockIops") + private Double blockIops; + @JsonProperty("blockUsed") + private Double blockUsed; + @JsonProperty("ephemeralConfigured") + private Double ephemeralConfigured; + @JsonProperty("ephemeralIops") + private Double ephemeralIops; + @JsonProperty("ephemeralUsed") + private Double ephemeralUsed; + @JsonProperty("filesystemName") + private String filesystemName; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("blockConfigured") + public Double getBlockConfigured() { + return blockConfigured; + } + + @JsonProperty("blockConfigured") + public void setBlockConfigured(Double blockConfigured) { + this.blockConfigured = blockConfigured; + } + + @JsonProperty("blockIops") + public Double getBlockIops() { + return blockIops; + } + + @JsonProperty("blockIops") + public void setBlockIops(Double blockIops) { + this.blockIops = blockIops; + } + + @JsonProperty("blockUsed") + public Double getBlockUsed() { + return blockUsed; + } + + @JsonProperty("blockUsed") + public void setBlockUsed(Double blockUsed) { + this.blockUsed = blockUsed; + } + + @JsonProperty("ephemeralConfigured") + public Double getEphemeralConfigured() { + return ephemeralConfigured; + } + + @JsonProperty("ephemeralConfigured") + public void setEphemeralConfigured(Double ephemeralConfigured) { + this.ephemeralConfigured = ephemeralConfigured; + } + + @JsonProperty("ephemeralIops") + public Double getEphemeralIops() { + return ephemeralIops; + } + + @JsonProperty("ephemeralIops") + public void setEphemeralIops(Double ephemeralIops) { + this.ephemeralIops = ephemeralIops; + } + + @JsonProperty("ephemeralUsed") + public Double getEphemeralUsed() { + return ephemeralUsed; + } + + @JsonProperty("ephemeralUsed") + public void setEphemeralUsed(Double ephemeralUsed) { + this.ephemeralUsed = ephemeralUsed; + } + + @JsonProperty("filesystemName") + public String getFilesystemName() { + return filesystemName; + } + + @JsonProperty("filesystemName") + public void setFilesystemName(String filesystemName) { + this.filesystemName = filesystemName; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("blockConfigured", blockConfigured).append("blockIops", blockIops).append("blockUsed", blockUsed).append("ephemeralConfigured", ephemeralConfigured).append("ephemeralIops", ephemeralIops).append("ephemeralUsed", ephemeralUsed).append("filesystemName", filesystemName).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(ephemeralUsed).append(blockConfigured).append(filesystemName).append(additionalProperties).append(ephemeralConfigured).append(ephemeralIops).append(blockIops).append(blockUsed).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof FilesystemUsageArray) == false) { + return false; + } + FilesystemUsageArray rhs = ((FilesystemUsageArray) other); + return new EqualsBuilder().append(ephemeralUsed, rhs.ephemeralUsed).append(blockConfigured, rhs.blockConfigured).append(filesystemName, rhs.filesystemName).append(additionalProperties, rhs.additionalProperties).append(ephemeralConfigured, rhs.ephemeralConfigured).append(ephemeralIops, rhs.ephemeralIops).append(blockIops, rhs.blockIops).append(blockUsed, rhs.blockUsed).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/GtpPerFlowMetrics.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/GtpPerFlowMetrics.java new file mode 100644 index 0000000..cff3dc4 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/GtpPerFlowMetrics.java @@ -0,0 +1,725 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "avgBitErrorRate", + "avgPacketDelayVariation", + "avgPacketLatency", + "avgReceiveThroughput", + "avgTransmitThroughput", + "flowActivationEpoch", + "flowActivationMicrosec", + "flowDeactivationEpoch", + "flowDeactivationMicrosec", + "flowDeactivationTime", + "flowStatus", + "maxPacketDelayVariation", + "numActivationFailures", + "numBitErrors", + "numBytesReceived", + "numBytesTransmitted", + "numDroppedPackets", + "numL7BytesReceived", + "numL7BytesTransmitted", + "numLostPackets", + "numOutOfOrderPackets", + "numPacketErrors", + "numPacketsReceivedExclRetrans", + "numPacketsReceivedInclRetrans", + "numPacketsTransmittedInclRetrans", + "numRetries", + "numTimeouts", + "numTunneledL7BytesReceived", + "roundTripTime", + "timeToFirstByte", + "durConnectionFailedStatus", + "durTunnelFailedStatus", + "flowActivatedBy", + "flowActivationTime", + "flowDeactivatedBy", + "gtpConnectionStatus", + "gtpTunnelStatus", + "ipTosCountList", + "ipTosList", + "largePacketRtt", + "largePacketThreshold", + "maxReceiveBitRate", + "maxTransmitBitRate", + "mobileQciCosCountList", + "mobileQciCosList", + "numGtpEchoFailures", + "numGtpTunnelErrors", + "numHttpErrors", + "tcpFlagCountList", + "tcpFlagList" +}) +public class GtpPerFlowMetrics { + + @JsonProperty("avgBitErrorRate") + private Double avgBitErrorRate; + @JsonProperty("avgPacketDelayVariation") + private Double avgPacketDelayVariation; + @JsonProperty("avgPacketLatency") + private Double avgPacketLatency; + @JsonProperty("avgReceiveThroughput") + private Double avgReceiveThroughput; + @JsonProperty("avgTransmitThroughput") + private Double avgTransmitThroughput; + @JsonProperty("flowActivationEpoch") + private Double flowActivationEpoch; + @JsonProperty("flowActivationMicrosec") + private Double flowActivationMicrosec; + @JsonProperty("flowDeactivationEpoch") + private Double flowDeactivationEpoch; + @JsonProperty("flowDeactivationMicrosec") + private Double flowDeactivationMicrosec; + @JsonProperty("flowDeactivationTime") + private String flowDeactivationTime; + @JsonProperty("flowStatus") + private String flowStatus; + @JsonProperty("maxPacketDelayVariation") + private Double maxPacketDelayVariation; + @JsonProperty("numActivationFailures") + private Double numActivationFailures; + @JsonProperty("numBitErrors") + private Double numBitErrors; + @JsonProperty("numBytesReceived") + private Double numBytesReceived; + @JsonProperty("numBytesTransmitted") + private Double numBytesTransmitted; + @JsonProperty("numDroppedPackets") + private Double numDroppedPackets; + @JsonProperty("numL7BytesReceived") + private Double numL7BytesReceived; + @JsonProperty("numL7BytesTransmitted") + private Double numL7BytesTransmitted; + @JsonProperty("numLostPackets") + private Double numLostPackets; + @JsonProperty("numOutOfOrderPackets") + private Double numOutOfOrderPackets; + @JsonProperty("numPacketErrors") + private Double numPacketErrors; + @JsonProperty("numPacketsReceivedExclRetrans") + private Double numPacketsReceivedExclRetrans; + @JsonProperty("numPacketsReceivedInclRetrans") + private Double numPacketsReceivedInclRetrans; + @JsonProperty("numPacketsTransmittedInclRetrans") + private Double numPacketsTransmittedInclRetrans; + @JsonProperty("numRetries") + private Double numRetries; + @JsonProperty("numTimeouts") + private Double numTimeouts; + @JsonProperty("numTunneledL7BytesReceived") + private Double numTunneledL7BytesReceived; + @JsonProperty("roundTripTime") + private Double roundTripTime; + @JsonProperty("timeToFirstByte") + private Double timeToFirstByte; + @JsonProperty("durConnectionFailedStatus") + private Double durConnectionFailedStatus; + @JsonProperty("durTunnelFailedStatus") + private Double durTunnelFailedStatus; + @JsonProperty("flowActivatedBy") + private String flowActivatedBy; + @JsonProperty("flowActivationTime") + private String flowActivationTime; + @JsonProperty("flowDeactivatedBy") + private String flowDeactivatedBy; + @JsonProperty("gtpConnectionStatus") + private String gtpConnectionStatus; + @JsonProperty("gtpTunnelStatus") + private String gtpTunnelStatus; + @JsonProperty("ipTosCountList") + private List<List<String>> ipTosCountList = null; + @JsonProperty("ipTosList") + private List<String> ipTosList = null; + @JsonProperty("largePacketRtt") + private Double largePacketRtt; + @JsonProperty("largePacketThreshold") + private Double largePacketThreshold; + @JsonProperty("maxReceiveBitRate") + private Double maxReceiveBitRate; + @JsonProperty("maxTransmitBitRate") + private Double maxTransmitBitRate; + @JsonProperty("mobileQciCosCountList") + private List<List<String>> mobileQciCosCountList = null; + @JsonProperty("mobileQciCosList") + private List<String> mobileQciCosList = null; + @JsonProperty("numGtpEchoFailures") + private Double numGtpEchoFailures; + @JsonProperty("numGtpTunnelErrors") + private Double numGtpTunnelErrors; + @JsonProperty("numHttpErrors") + private Double numHttpErrors; + @JsonProperty("tcpFlagCountList") + private List<List<String>> tcpFlagCountList = null; + @JsonProperty("tcpFlagList") + private List<String> tcpFlagList = null; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("avgBitErrorRate") + public Double getAvgBitErrorRate() { + return avgBitErrorRate; + } + + @JsonProperty("avgBitErrorRate") + public void setAvgBitErrorRate(Double avgBitErrorRate) { + this.avgBitErrorRate = avgBitErrorRate; + } + + @JsonProperty("avgPacketDelayVariation") + public Double getAvgPacketDelayVariation() { + return avgPacketDelayVariation; + } + + @JsonProperty("avgPacketDelayVariation") + public void setAvgPacketDelayVariation(Double avgPacketDelayVariation) { + this.avgPacketDelayVariation = avgPacketDelayVariation; + } + + @JsonProperty("avgPacketLatency") + public Double getAvgPacketLatency() { + return avgPacketLatency; + } + + @JsonProperty("avgPacketLatency") + public void setAvgPacketLatency(Double avgPacketLatency) { + this.avgPacketLatency = avgPacketLatency; + } + + @JsonProperty("avgReceiveThroughput") + public Double getAvgReceiveThroughput() { + return avgReceiveThroughput; + } + + @JsonProperty("avgReceiveThroughput") + public void setAvgReceiveThroughput(Double avgReceiveThroughput) { + this.avgReceiveThroughput = avgReceiveThroughput; + } + + @JsonProperty("avgTransmitThroughput") + public Double getAvgTransmitThroughput() { + return avgTransmitThroughput; + } + + @JsonProperty("avgTransmitThroughput") + public void setAvgTransmitThroughput(Double avgTransmitThroughput) { + this.avgTransmitThroughput = avgTransmitThroughput; + } + + @JsonProperty("flowActivationEpoch") + public Double getFlowActivationEpoch() { + return flowActivationEpoch; + } + + @JsonProperty("flowActivationEpoch") + public void setFlowActivationEpoch(Double flowActivationEpoch) { + this.flowActivationEpoch = flowActivationEpoch; + } + + @JsonProperty("flowActivationMicrosec") + public Double getFlowActivationMicrosec() { + return flowActivationMicrosec; + } + + @JsonProperty("flowActivationMicrosec") + public void setFlowActivationMicrosec(Double flowActivationMicrosec) { + this.flowActivationMicrosec = flowActivationMicrosec; + } + + @JsonProperty("flowDeactivationEpoch") + public Double getFlowDeactivationEpoch() { + return flowDeactivationEpoch; + } + + @JsonProperty("flowDeactivationEpoch") + public void setFlowDeactivationEpoch(Double flowDeactivationEpoch) { + this.flowDeactivationEpoch = flowDeactivationEpoch; + } + + @JsonProperty("flowDeactivationMicrosec") + public Double getFlowDeactivationMicrosec() { + return flowDeactivationMicrosec; + } + + @JsonProperty("flowDeactivationMicrosec") + public void setFlowDeactivationMicrosec(Double flowDeactivationMicrosec) { + this.flowDeactivationMicrosec = flowDeactivationMicrosec; + } + + @JsonProperty("flowDeactivationTime") + public String getFlowDeactivationTime() { + return flowDeactivationTime; + } + + @JsonProperty("flowDeactivationTime") + public void setFlowDeactivationTime(String flowDeactivationTime) { + this.flowDeactivationTime = flowDeactivationTime; + } + + @JsonProperty("flowStatus") + public String getFlowStatus() { + return flowStatus; + } + + @JsonProperty("flowStatus") + public void setFlowStatus(String flowStatus) { + this.flowStatus = flowStatus; + } + + @JsonProperty("maxPacketDelayVariation") + public Double getMaxPacketDelayVariation() { + return maxPacketDelayVariation; + } + + @JsonProperty("maxPacketDelayVariation") + public void setMaxPacketDelayVariation(Double maxPacketDelayVariation) { + this.maxPacketDelayVariation = maxPacketDelayVariation; + } + + @JsonProperty("numActivationFailures") + public Double getNumActivationFailures() { + return numActivationFailures; + } + + @JsonProperty("numActivationFailures") + public void setNumActivationFailures(Double numActivationFailures) { + this.numActivationFailures = numActivationFailures; + } + + @JsonProperty("numBitErrors") + public Double getNumBitErrors() { + return numBitErrors; + } + + @JsonProperty("numBitErrors") + public void setNumBitErrors(Double numBitErrors) { + this.numBitErrors = numBitErrors; + } + + @JsonProperty("numBytesReceived") + public Double getNumBytesReceived() { + return numBytesReceived; + } + + @JsonProperty("numBytesReceived") + public void setNumBytesReceived(Double numBytesReceived) { + this.numBytesReceived = numBytesReceived; + } + + @JsonProperty("numBytesTransmitted") + public Double getNumBytesTransmitted() { + return numBytesTransmitted; + } + + @JsonProperty("numBytesTransmitted") + public void setNumBytesTransmitted(Double numBytesTransmitted) { + this.numBytesTransmitted = numBytesTransmitted; + } + + @JsonProperty("numDroppedPackets") + public Double getNumDroppedPackets() { + return numDroppedPackets; + } + + @JsonProperty("numDroppedPackets") + public void setNumDroppedPackets(Double numDroppedPackets) { + this.numDroppedPackets = numDroppedPackets; + } + + @JsonProperty("numL7BytesReceived") + public Double getNumL7BytesReceived() { + return numL7BytesReceived; + } + + @JsonProperty("numL7BytesReceived") + public void setNumL7BytesReceived(Double numL7BytesReceived) { + this.numL7BytesReceived = numL7BytesReceived; + } + + @JsonProperty("numL7BytesTransmitted") + public Double getNumL7BytesTransmitted() { + return numL7BytesTransmitted; + } + + @JsonProperty("numL7BytesTransmitted") + public void setNumL7BytesTransmitted(Double numL7BytesTransmitted) { + this.numL7BytesTransmitted = numL7BytesTransmitted; + } + + @JsonProperty("numLostPackets") + public Double getNumLostPackets() { + return numLostPackets; + } + + @JsonProperty("numLostPackets") + public void setNumLostPackets(Double numLostPackets) { + this.numLostPackets = numLostPackets; + } + + @JsonProperty("numOutOfOrderPackets") + public Double getNumOutOfOrderPackets() { + return numOutOfOrderPackets; + } + + @JsonProperty("numOutOfOrderPackets") + public void setNumOutOfOrderPackets(Double numOutOfOrderPackets) { + this.numOutOfOrderPackets = numOutOfOrderPackets; + } + + @JsonProperty("numPacketErrors") + public Double getNumPacketErrors() { + return numPacketErrors; + } + + @JsonProperty("numPacketErrors") + public void setNumPacketErrors(Double numPacketErrors) { + this.numPacketErrors = numPacketErrors; + } + + @JsonProperty("numPacketsReceivedExclRetrans") + public Double getNumPacketsReceivedExclRetrans() { + return numPacketsReceivedExclRetrans; + } + + @JsonProperty("numPacketsReceivedExclRetrans") + public void setNumPacketsReceivedExclRetrans(Double numPacketsReceivedExclRetrans) { + this.numPacketsReceivedExclRetrans = numPacketsReceivedExclRetrans; + } + + @JsonProperty("numPacketsReceivedInclRetrans") + public Double getNumPacketsReceivedInclRetrans() { + return numPacketsReceivedInclRetrans; + } + + @JsonProperty("numPacketsReceivedInclRetrans") + public void setNumPacketsReceivedInclRetrans(Double numPacketsReceivedInclRetrans) { + this.numPacketsReceivedInclRetrans = numPacketsReceivedInclRetrans; + } + + @JsonProperty("numPacketsTransmittedInclRetrans") + public Double getNumPacketsTransmittedInclRetrans() { + return numPacketsTransmittedInclRetrans; + } + + @JsonProperty("numPacketsTransmittedInclRetrans") + public void setNumPacketsTransmittedInclRetrans(Double numPacketsTransmittedInclRetrans) { + this.numPacketsTransmittedInclRetrans = numPacketsTransmittedInclRetrans; + } + + @JsonProperty("numRetries") + public Double getNumRetries() { + return numRetries; + } + + @JsonProperty("numRetries") + public void setNumRetries(Double numRetries) { + this.numRetries = numRetries; + } + + @JsonProperty("numTimeouts") + public Double getNumTimeouts() { + return numTimeouts; + } + + @JsonProperty("numTimeouts") + public void setNumTimeouts(Double numTimeouts) { + this.numTimeouts = numTimeouts; + } + + @JsonProperty("numTunneledL7BytesReceived") + public Double getNumTunneledL7BytesReceived() { + return numTunneledL7BytesReceived; + } + + @JsonProperty("numTunneledL7BytesReceived") + public void setNumTunneledL7BytesReceived(Double numTunneledL7BytesReceived) { + this.numTunneledL7BytesReceived = numTunneledL7BytesReceived; + } + + @JsonProperty("roundTripTime") + public Double getRoundTripTime() { + return roundTripTime; + } + + @JsonProperty("roundTripTime") + public void setRoundTripTime(Double roundTripTime) { + this.roundTripTime = roundTripTime; + } + + @JsonProperty("timeToFirstByte") + public Double getTimeToFirstByte() { + return timeToFirstByte; + } + + @JsonProperty("timeToFirstByte") + public void setTimeToFirstByte(Double timeToFirstByte) { + this.timeToFirstByte = timeToFirstByte; + } + + @JsonProperty("durConnectionFailedStatus") + public Double getDurConnectionFailedStatus() { + return durConnectionFailedStatus; + } + + @JsonProperty("durConnectionFailedStatus") + public void setDurConnectionFailedStatus(Double durConnectionFailedStatus) { + this.durConnectionFailedStatus = durConnectionFailedStatus; + } + + @JsonProperty("durTunnelFailedStatus") + public Double getDurTunnelFailedStatus() { + return durTunnelFailedStatus; + } + + @JsonProperty("durTunnelFailedStatus") + public void setDurTunnelFailedStatus(Double durTunnelFailedStatus) { + this.durTunnelFailedStatus = durTunnelFailedStatus; + } + + @JsonProperty("flowActivatedBy") + public String getFlowActivatedBy() { + return flowActivatedBy; + } + + @JsonProperty("flowActivatedBy") + public void setFlowActivatedBy(String flowActivatedBy) { + this.flowActivatedBy = flowActivatedBy; + } + + @JsonProperty("flowActivationTime") + public String getFlowActivationTime() { + return flowActivationTime; + } + + @JsonProperty("flowActivationTime") + public void setFlowActivationTime(String flowActivationTime) { + this.flowActivationTime = flowActivationTime; + } + + @JsonProperty("flowDeactivatedBy") + public String getFlowDeactivatedBy() { + return flowDeactivatedBy; + } + + @JsonProperty("flowDeactivatedBy") + public void setFlowDeactivatedBy(String flowDeactivatedBy) { + this.flowDeactivatedBy = flowDeactivatedBy; + } + + @JsonProperty("gtpConnectionStatus") + public String getGtpConnectionStatus() { + return gtpConnectionStatus; + } + + @JsonProperty("gtpConnectionStatus") + public void setGtpConnectionStatus(String gtpConnectionStatus) { + this.gtpConnectionStatus = gtpConnectionStatus; + } + + @JsonProperty("gtpTunnelStatus") + public String getGtpTunnelStatus() { + return gtpTunnelStatus; + } + + @JsonProperty("gtpTunnelStatus") + public void setGtpTunnelStatus(String gtpTunnelStatus) { + this.gtpTunnelStatus = gtpTunnelStatus; + } + + @JsonProperty("ipTosCountList") + public List<List<String>> getIpTosCountList() { + return ipTosCountList; + } + + @JsonProperty("ipTosCountList") + public void setIpTosCountList(List<List<String>> ipTosCountList) { + this.ipTosCountList = ipTosCountList; + } + + @JsonProperty("ipTosList") + public List<String> getIpTosList() { + return ipTosList; + } + + @JsonProperty("ipTosList") + public void setIpTosList(List<String> ipTosList) { + this.ipTosList = ipTosList; + } + + @JsonProperty("largePacketRtt") + public Double getLargePacketRtt() { + return largePacketRtt; + } + + @JsonProperty("largePacketRtt") + public void setLargePacketRtt(Double largePacketRtt) { + this.largePacketRtt = largePacketRtt; + } + + @JsonProperty("largePacketThreshold") + public Double getLargePacketThreshold() { + return largePacketThreshold; + } + + @JsonProperty("largePacketThreshold") + public void setLargePacketThreshold(Double largePacketThreshold) { + this.largePacketThreshold = largePacketThreshold; + } + + @JsonProperty("maxReceiveBitRate") + public Double getMaxReceiveBitRate() { + return maxReceiveBitRate; + } + + @JsonProperty("maxReceiveBitRate") + public void setMaxReceiveBitRate(Double maxReceiveBitRate) { + this.maxReceiveBitRate = maxReceiveBitRate; + } + + @JsonProperty("maxTransmitBitRate") + public Double getMaxTransmitBitRate() { + return maxTransmitBitRate; + } + + @JsonProperty("maxTransmitBitRate") + public void setMaxTransmitBitRate(Double maxTransmitBitRate) { + this.maxTransmitBitRate = maxTransmitBitRate; + } + + @JsonProperty("mobileQciCosCountList") + public List<List<String>> getMobileQciCosCountList() { + return mobileQciCosCountList; + } + + @JsonProperty("mobileQciCosCountList") + public void setMobileQciCosCountList(List<List<String>> mobileQciCosCountList) { + this.mobileQciCosCountList = mobileQciCosCountList; + } + + @JsonProperty("mobileQciCosList") + public List<String> getMobileQciCosList() { + return mobileQciCosList; + } + + @JsonProperty("mobileQciCosList") + public void setMobileQciCosList(List<String> mobileQciCosList) { + this.mobileQciCosList = mobileQciCosList; + } + + @JsonProperty("numGtpEchoFailures") + public Double getNumGtpEchoFailures() { + return numGtpEchoFailures; + } + + @JsonProperty("numGtpEchoFailures") + public void setNumGtpEchoFailures(Double numGtpEchoFailures) { + this.numGtpEchoFailures = numGtpEchoFailures; + } + + @JsonProperty("numGtpTunnelErrors") + public Double getNumGtpTunnelErrors() { + return numGtpTunnelErrors; + } + + @JsonProperty("numGtpTunnelErrors") + public void setNumGtpTunnelErrors(Double numGtpTunnelErrors) { + this.numGtpTunnelErrors = numGtpTunnelErrors; + } + + @JsonProperty("numHttpErrors") + public Double getNumHttpErrors() { + return numHttpErrors; + } + + @JsonProperty("numHttpErrors") + public void setNumHttpErrors(Double numHttpErrors) { + this.numHttpErrors = numHttpErrors; + } + + @JsonProperty("tcpFlagCountList") + public List<List<String>> getTcpFlagCountList() { + return tcpFlagCountList; + } + + @JsonProperty("tcpFlagCountList") + public void setTcpFlagCountList(List<List<String>> tcpFlagCountList) { + this.tcpFlagCountList = tcpFlagCountList; + } + + @JsonProperty("tcpFlagList") + public List<String> getTcpFlagList() { + return tcpFlagList; + } + + @JsonProperty("tcpFlagList") + public void setTcpFlagList(List<String> tcpFlagList) { + this.tcpFlagList = tcpFlagList; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("avgBitErrorRate", avgBitErrorRate).append("avgPacketDelayVariation", avgPacketDelayVariation).append("avgPacketLatency", avgPacketLatency).append("avgReceiveThroughput", avgReceiveThroughput).append("avgTransmitThroughput", avgTransmitThroughput).append("flowActivationEpoch", flowActivationEpoch).append("flowActivationMicrosec", flowActivationMicrosec).append("flowDeactivationEpoch", flowDeactivationEpoch).append("flowDeactivationMicrosec", flowDeactivationMicrosec).append("flowDeactivationTime", flowDeactivationTime).append("flowStatus", flowStatus).append("maxPacketDelayVariation", maxPacketDelayVariation).append("numActivationFailures", numActivationFailures).append("numBitErrors", numBitErrors).append("numBytesReceived", numBytesReceived).append("numBytesTransmitted", numBytesTransmitted).append("numDroppedPackets", numDroppedPackets).append("numL7BytesReceived", numL7BytesReceived).append("numL7BytesTransmitted", numL7BytesTransmitted).append("numLostPackets", numLostPackets).append("numOutOfOrderPackets", numOutOfOrderPackets).append("numPacketErrors", numPacketErrors).append("numPacketsReceivedExclRetrans", numPacketsReceivedExclRetrans).append("numPacketsReceivedInclRetrans", numPacketsReceivedInclRetrans).append("numPacketsTransmittedInclRetrans", numPacketsTransmittedInclRetrans).append("numRetries", numRetries).append("numTimeouts", numTimeouts).append("numTunneledL7BytesReceived", numTunneledL7BytesReceived).append("roundTripTime", roundTripTime).append("timeToFirstByte", timeToFirstByte).append("durConnectionFailedStatus", durConnectionFailedStatus).append("durTunnelFailedStatus", durTunnelFailedStatus).append("flowActivatedBy", flowActivatedBy).append("flowActivationTime", flowActivationTime).append("flowDeactivatedBy", flowDeactivatedBy).append("gtpConnectionStatus", gtpConnectionStatus).append("gtpTunnelStatus", gtpTunnelStatus).append("ipTosCountList", ipTosCountList).append("ipTosList", ipTosList).append("largePacketRtt", largePacketRtt).append("largePacketThreshold", largePacketThreshold).append("maxReceiveBitRate", maxReceiveBitRate).append("maxTransmitBitRate", maxTransmitBitRate).append("mobileQciCosCountList", mobileQciCosCountList).append("mobileQciCosList", mobileQciCosList).append("numGtpEchoFailures", numGtpEchoFailures).append("numGtpTunnelErrors", numGtpTunnelErrors).append("numHttpErrors", numHttpErrors).append("tcpFlagCountList", tcpFlagCountList).append("tcpFlagList", tcpFlagList).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(avgPacketDelayVariation).append(flowActivationTime).append(numPacketsReceivedInclRetrans).append(flowActivationEpoch).append(maxPacketDelayVariation).append(ipTosList).append(flowStatus).append(flowDeactivationEpoch).append(numL7BytesReceived).append(avgReceiveThroughput).append(numGtpTunnelErrors).append(numPacketsTransmittedInclRetrans).append(maxTransmitBitRate).append(ipTosCountList).append(gtpTunnelStatus).append(numBitErrors).append(timeToFirstByte).append(mobileQciCosList).append(numTunneledL7BytesReceived).append(additionalProperties).append(gtpConnectionStatus).append(numPacketErrors).append(tcpFlagCountList).append(flowDeactivatedBy).append(avgTransmitThroughput).append(roundTripTime).append(numBytesTransmitted).append(flowActivatedBy).append(numHttpErrors).append(numDroppedPackets).append(numL7BytesTransmitted).append(largePacketRtt).append(largePacketThreshold).append(durTunnelFailedStatus).append(numLostPackets).append(numGtpEchoFailures).append(flowDeactivationTime).append(flowActivationMicrosec).append(mobileQciCosCountList).append(avgBitErrorRate).append(numBytesReceived).append(avgPacketLatency).append(numTimeouts).append(maxReceiveBitRate).append(numPacketsReceivedExclRetrans).append(flowDeactivationMicrosec).append(numRetries).append(numOutOfOrderPackets).append(tcpFlagList).append(durConnectionFailedStatus).append(numActivationFailures).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof GtpPerFlowMetrics) == false) { + return false; + } + GtpPerFlowMetrics rhs = ((GtpPerFlowMetrics) other); + return new EqualsBuilder().append(avgPacketDelayVariation, rhs.avgPacketDelayVariation).append(flowActivationTime, rhs.flowActivationTime).append(numPacketsReceivedInclRetrans, rhs.numPacketsReceivedInclRetrans).append(flowActivationEpoch, rhs.flowActivationEpoch).append(maxPacketDelayVariation, rhs.maxPacketDelayVariation).append(ipTosList, rhs.ipTosList).append(flowStatus, rhs.flowStatus).append(flowDeactivationEpoch, rhs.flowDeactivationEpoch).append(numL7BytesReceived, rhs.numL7BytesReceived).append(avgReceiveThroughput, rhs.avgReceiveThroughput).append(numGtpTunnelErrors, rhs.numGtpTunnelErrors).append(numPacketsTransmittedInclRetrans, rhs.numPacketsTransmittedInclRetrans).append(maxTransmitBitRate, rhs.maxTransmitBitRate).append(ipTosCountList, rhs.ipTosCountList).append(gtpTunnelStatus, rhs.gtpTunnelStatus).append(numBitErrors, rhs.numBitErrors).append(timeToFirstByte, rhs.timeToFirstByte).append(mobileQciCosList, rhs.mobileQciCosList).append(numTunneledL7BytesReceived, rhs.numTunneledL7BytesReceived).append(additionalProperties, rhs.additionalProperties).append(gtpConnectionStatus, rhs.gtpConnectionStatus).append(numPacketErrors, rhs.numPacketErrors).append(tcpFlagCountList, rhs.tcpFlagCountList).append(flowDeactivatedBy, rhs.flowDeactivatedBy).append(avgTransmitThroughput, rhs.avgTransmitThroughput).append(roundTripTime, rhs.roundTripTime).append(numBytesTransmitted, rhs.numBytesTransmitted).append(flowActivatedBy, rhs.flowActivatedBy).append(numHttpErrors, rhs.numHttpErrors).append(numDroppedPackets, rhs.numDroppedPackets).append(numL7BytesTransmitted, rhs.numL7BytesTransmitted).append(largePacketRtt, rhs.largePacketRtt).append(largePacketThreshold, rhs.largePacketThreshold).append(durTunnelFailedStatus, rhs.durTunnelFailedStatus).append(numLostPackets, rhs.numLostPackets).append(numGtpEchoFailures, rhs.numGtpEchoFailures).append(flowDeactivationTime, rhs.flowDeactivationTime).append(flowActivationMicrosec, rhs.flowActivationMicrosec).append(mobileQciCosCountList, rhs.mobileQciCosCountList).append(avgBitErrorRate, rhs.avgBitErrorRate).append(numBytesReceived, rhs.numBytesReceived).append(avgPacketLatency, rhs.avgPacketLatency).append(numTimeouts, rhs.numTimeouts).append(maxReceiveBitRate, rhs.maxReceiveBitRate).append(numPacketsReceivedExclRetrans, rhs.numPacketsReceivedExclRetrans).append(flowDeactivationMicrosec, rhs.flowDeactivationMicrosec).append(numRetries, rhs.numRetries).append(numOutOfOrderPackets, rhs.numOutOfOrderPackets).append(tcpFlagList, rhs.tcpFlagList).append(durConnectionFailedStatus, rhs.durConnectionFailedStatus).append(numActivationFailures, rhs.numActivationFailures).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/HashOfNameValuePairArray.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/HashOfNameValuePairArray.java new file mode 100644 index 0000000..c44edf3 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/HashOfNameValuePairArray.java @@ -0,0 +1,101 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "name", + "arrayOfFields" +}) +public class HashOfNameValuePairArray { + + @JsonProperty("name") + private String name; + @JsonProperty("arrayOfFields") + private List<ArrayOfField_> arrayOfFields = null; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("name") + public String getName() { + return name; + } + + @JsonProperty("name") + public void setName(String name) { + this.name = name; + } + + @JsonProperty("arrayOfFields") + public List<ArrayOfField_> getArrayOfFields() { + return arrayOfFields; + } + + @JsonProperty("arrayOfFields") + public void setArrayOfFields(List<ArrayOfField_> arrayOfFields) { + this.arrayOfFields = arrayOfFields; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("name", name).append("arrayOfFields", arrayOfFields).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(arrayOfFields).append(additionalProperties).append(name).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof HashOfNameValuePairArray) == false) { + return false; + } + HashOfNameValuePairArray rhs = ((HashOfNameValuePairArray) other); + return new EqualsBuilder().append(arrayOfFields, rhs.arrayOfFields).append(additionalProperties, rhs.additionalProperties).append(name, rhs.name).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/JsonObject.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/JsonObject.java new file mode 100644 index 0000000..e49ddd7 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/JsonObject.java @@ -0,0 +1,154 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; +import org.onap.dcaegen2.ves.domain.ObjectInstance; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "objectInstances", + "objectName", + "objectSchema", + "objectSchemaUrl", + "nfSubscribedObjectName", + "nfSubscriptionId" +}) +public class JsonObject { + + @JsonProperty("objectInstances") + private List<ObjectInstance> objectInstances = null; + @JsonProperty("objectName") + private String objectName; + @JsonProperty("objectSchema") + private String objectSchema; + @JsonProperty("objectSchemaUrl") + private String objectSchemaUrl; + @JsonProperty("nfSubscribedObjectName") + private String nfSubscribedObjectName; + @JsonProperty("nfSubscriptionId") + private String nfSubscriptionId; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("objectInstances") + public List<ObjectInstance> getObjectInstances() { + return objectInstances; + } + + @JsonProperty("objectInstances") + public void setObjectInstances(List<ObjectInstance> objectInstances) { + this.objectInstances = objectInstances; + } + + @JsonProperty("objectName") + public String getObjectName() { + return objectName; + } + + @JsonProperty("objectName") + public void setObjectName(String objectName) { + this.objectName = objectName; + } + + @JsonProperty("objectSchema") + public String getObjectSchema() { + return objectSchema; + } + + @JsonProperty("objectSchema") + public void setObjectSchema(String objectSchema) { + this.objectSchema = objectSchema; + } + + @JsonProperty("objectSchemaUrl") + public String getObjectSchemaUrl() { + return objectSchemaUrl; + } + + @JsonProperty("objectSchemaUrl") + public void setObjectSchemaUrl(String objectSchemaUrl) { + this.objectSchemaUrl = objectSchemaUrl; + } + + @JsonProperty("nfSubscribedObjectName") + public String getNfSubscribedObjectName() { + return nfSubscribedObjectName; + } + + @JsonProperty("nfSubscribedObjectName") + public void setNfSubscribedObjectName(String nfSubscribedObjectName) { + this.nfSubscribedObjectName = nfSubscribedObjectName; + } + + @JsonProperty("nfSubscriptionId") + public String getNfSubscriptionId() { + return nfSubscriptionId; + } + + @JsonProperty("nfSubscriptionId") + public void setNfSubscriptionId(String nfSubscriptionId) { + this.nfSubscriptionId = nfSubscriptionId; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("objectInstances", objectInstances).append("objectName", objectName).append("objectSchema", objectSchema).append("objectSchemaUrl", objectSchemaUrl).append("nfSubscribedObjectName", nfSubscribedObjectName).append("nfSubscriptionId", nfSubscriptionId).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(nfSubscribedObjectName).append(nfSubscriptionId).append(objectName).append(additionalProperties).append(objectInstances).append(objectSchemaUrl).append(objectSchema).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof JsonObject) == false) { + return false; + } + JsonObject rhs = ((JsonObject) other); + return new EqualsBuilder().append(nfSubscribedObjectName, rhs.nfSubscribedObjectName).append(nfSubscriptionId, rhs.nfSubscriptionId).append(objectName, rhs.objectName).append(additionalProperties, rhs.additionalProperties).append(objectInstances, rhs.objectInstances).append(objectSchemaUrl, rhs.objectSchemaUrl).append(objectSchema, rhs.objectSchema).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/LatencyDistribution.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/LatencyDistribution.java new file mode 100644 index 0000000..56d54cf --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/LatencyDistribution.java @@ -0,0 +1,113 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "countsInTheBucket", + "highEndOfLatencyBucket", + "lowEndOfLatencyBucket" +}) +public class LatencyDistribution { + + @JsonProperty("countsInTheBucket") + private Double countsInTheBucket; + @JsonProperty("highEndOfLatencyBucket") + private Double highEndOfLatencyBucket; + @JsonProperty("lowEndOfLatencyBucket") + private Double lowEndOfLatencyBucket; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("countsInTheBucket") + public Double getCountsInTheBucket() { + return countsInTheBucket; + } + + @JsonProperty("countsInTheBucket") + public void setCountsInTheBucket(Double countsInTheBucket) { + this.countsInTheBucket = countsInTheBucket; + } + + @JsonProperty("highEndOfLatencyBucket") + public Double getHighEndOfLatencyBucket() { + return highEndOfLatencyBucket; + } + + @JsonProperty("highEndOfLatencyBucket") + public void setHighEndOfLatencyBucket(Double highEndOfLatencyBucket) { + this.highEndOfLatencyBucket = highEndOfLatencyBucket; + } + + @JsonProperty("lowEndOfLatencyBucket") + public Double getLowEndOfLatencyBucket() { + return lowEndOfLatencyBucket; + } + + @JsonProperty("lowEndOfLatencyBucket") + public void setLowEndOfLatencyBucket(Double lowEndOfLatencyBucket) { + this.lowEndOfLatencyBucket = lowEndOfLatencyBucket; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("countsInTheBucket", countsInTheBucket).append("highEndOfLatencyBucket", highEndOfLatencyBucket).append("lowEndOfLatencyBucket", lowEndOfLatencyBucket).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(countsInTheBucket).append(additionalProperties).append(highEndOfLatencyBucket).append(lowEndOfLatencyBucket).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof LatencyDistribution) == false) { + return false; + } + LatencyDistribution rhs = ((LatencyDistribution) other); + return new EqualsBuilder().append(countsInTheBucket, rhs.countsInTheBucket).append(additionalProperties, rhs.additionalProperties).append(highEndOfLatencyBucket, rhs.highEndOfLatencyBucket).append(lowEndOfLatencyBucket, rhs.lowEndOfLatencyBucket).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/MeasurementsForVfScalingFields.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/MeasurementsForVfScalingFields.java new file mode 100644 index 0000000..65cc5e8 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/MeasurementsForVfScalingFields.java @@ -0,0 +1,322 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "measurementInterval", + "measurementsForVfScalingVersion", + "additionalFields", + "additionalMeasurements", + "additionalObjects", + "codecUsageArray", + "concurrentSessions", + "configuredEntities", + "cpuUsageArray", + "diskUsageArray", + "featureUsageArray", + "filesystemUsageArray", + "latencyDistribution", + "meanRequestLatency", + "memoryUsageArray", + "numberOfMediaPortsInUse", + "requestRate", + "vnfcScalingMetric", + "vNicPerformanceArray" +}) +public class MeasurementsForVfScalingFields { + + @JsonProperty("measurementInterval") + private Double measurementInterval; + @JsonProperty("measurementsForVfScalingVersion") + private Double measurementsForVfScalingVersion; + @JsonProperty("additionalFields") + private List<AdditionalField> additionalFields = null; + @JsonProperty("additionalMeasurements") + private List<AdditionalMeasurement> additionalMeasurements = null; + @JsonProperty("additionalObjects") + private List<AdditionalObject> additionalObjects = null; + @JsonProperty("codecUsageArray") + private List<CodecUsageArray> codecUsageArray = null; + @JsonProperty("concurrentSessions") + private Long concurrentSessions; + @JsonProperty("configuredEntities") + private Long configuredEntities; + @JsonProperty("cpuUsageArray") + private List<CpuUsageArray> cpuUsageArray = null; + @JsonProperty("diskUsageArray") + private List<DiskUsageArray> diskUsageArray = null; + @JsonProperty("featureUsageArray") + private List<FeatureUsageArray> featureUsageArray = null; + @JsonProperty("filesystemUsageArray") + private List<FilesystemUsageArray> filesystemUsageArray = null; + @JsonProperty("latencyDistribution") + private List<LatencyDistribution> latencyDistribution = null; + @JsonProperty("meanRequestLatency") + private Double meanRequestLatency; + @JsonProperty("memoryUsageArray") + private List<MemoryUsageArray> memoryUsageArray = null; + @JsonProperty("numberOfMediaPortsInUse") + private Long numberOfMediaPortsInUse; + @JsonProperty("requestRate") + private Double requestRate; + @JsonProperty("vnfcScalingMetric") + private Long vnfcScalingMetric; + @JsonProperty("vNicPerformanceArray") + private List<VNicPerformanceArray> vNicPerformanceArray = null; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("measurementInterval") + public Double getMeasurementInterval() { + return measurementInterval; + } + + @JsonProperty("measurementInterval") + public void setMeasurementInterval(Double measurementInterval) { + this.measurementInterval = measurementInterval; + } + + @JsonProperty("measurementsForVfScalingVersion") + public Double getMeasurementsForVfScalingVersion() { + return measurementsForVfScalingVersion; + } + + @JsonProperty("measurementsForVfScalingVersion") + public void setMeasurementsForVfScalingVersion(Double measurementsForVfScalingVersion) { + this.measurementsForVfScalingVersion = measurementsForVfScalingVersion; + } + + @JsonProperty("additionalFields") + public List<AdditionalField> getAdditionalFields() { + return additionalFields; + } + + @JsonProperty("additionalFields") + public void setAdditionalFields(List<AdditionalField> additionalFields) { + this.additionalFields = additionalFields; + } + + @JsonProperty("additionalMeasurements") + public List<AdditionalMeasurement> getAdditionalMeasurements() { + return additionalMeasurements; + } + + @JsonProperty("additionalMeasurements") + public void setAdditionalMeasurements(List<AdditionalMeasurement> additionalMeasurements) { + this.additionalMeasurements = additionalMeasurements; + } + + @JsonProperty("additionalObjects") + public List<AdditionalObject> getAdditionalObjects() { + return additionalObjects; + } + + @JsonProperty("additionalObjects") + public void setAdditionalObjects(List<AdditionalObject> additionalObjects) { + this.additionalObjects = additionalObjects; + } + + @JsonProperty("codecUsageArray") + public List<CodecUsageArray> getCodecUsageArray() { + return codecUsageArray; + } + + @JsonProperty("codecUsageArray") + public void setCodecUsageArray(List<CodecUsageArray> codecUsageArray) { + this.codecUsageArray = codecUsageArray; + } + + @JsonProperty("concurrentSessions") + public Long getConcurrentSessions() { + return concurrentSessions; + } + + @JsonProperty("concurrentSessions") + public void setConcurrentSessions(Long concurrentSessions) { + this.concurrentSessions = concurrentSessions; + } + + @JsonProperty("configuredEntities") + public Long getConfiguredEntities() { + return configuredEntities; + } + + @JsonProperty("configuredEntities") + public void setConfiguredEntities(Long configuredEntities) { + this.configuredEntities = configuredEntities; + } + + @JsonProperty("cpuUsageArray") + public List<CpuUsageArray> getCpuUsageArray() { + return cpuUsageArray; + } + + @JsonProperty("cpuUsageArray") + public void setCpuUsageArray(List<CpuUsageArray> cpuUsageArray) { + this.cpuUsageArray = cpuUsageArray; + } + + @JsonProperty("diskUsageArray") + public List<DiskUsageArray> getDiskUsageArray() { + return diskUsageArray; + } + + @JsonProperty("diskUsageArray") + public void setDiskUsageArray(List<DiskUsageArray> diskUsageArray) { + this.diskUsageArray = diskUsageArray; + } + + @JsonProperty("featureUsageArray") + public List<FeatureUsageArray> getFeatureUsageArray() { + return featureUsageArray; + } + + @JsonProperty("featureUsageArray") + public void setFeatureUsageArray(List<FeatureUsageArray> featureUsageArray) { + this.featureUsageArray = featureUsageArray; + } + + @JsonProperty("filesystemUsageArray") + public List<FilesystemUsageArray> getFilesystemUsageArray() { + return filesystemUsageArray; + } + + @JsonProperty("filesystemUsageArray") + public void setFilesystemUsageArray(List<FilesystemUsageArray> filesystemUsageArray) { + this.filesystemUsageArray = filesystemUsageArray; + } + + @JsonProperty("latencyDistribution") + public List<LatencyDistribution> getLatencyDistribution() { + return latencyDistribution; + } + + @JsonProperty("latencyDistribution") + public void setLatencyDistribution(List<LatencyDistribution> latencyDistribution) { + this.latencyDistribution = latencyDistribution; + } + + @JsonProperty("meanRequestLatency") + public Double getMeanRequestLatency() { + return meanRequestLatency; + } + + @JsonProperty("meanRequestLatency") + public void setMeanRequestLatency(Double meanRequestLatency) { + this.meanRequestLatency = meanRequestLatency; + } + + @JsonProperty("memoryUsageArray") + public List<MemoryUsageArray> getMemoryUsageArray() { + return memoryUsageArray; + } + + @JsonProperty("memoryUsageArray") + public void setMemoryUsageArray(List<MemoryUsageArray> memoryUsageArray) { + this.memoryUsageArray = memoryUsageArray; + } + + @JsonProperty("numberOfMediaPortsInUse") + public Long getNumberOfMediaPortsInUse() { + return numberOfMediaPortsInUse; + } + + @JsonProperty("numberOfMediaPortsInUse") + public void setNumberOfMediaPortsInUse(Long numberOfMediaPortsInUse) { + this.numberOfMediaPortsInUse = numberOfMediaPortsInUse; + } + + @JsonProperty("requestRate") + public Double getRequestRate() { + return requestRate; + } + + @JsonProperty("requestRate") + public void setRequestRate(Double requestRate) { + this.requestRate = requestRate; + } + + @JsonProperty("vnfcScalingMetric") + public Long getVnfcScalingMetric() { + return vnfcScalingMetric; + } + + @JsonProperty("vnfcScalingMetric") + public void setVnfcScalingMetric(Long vnfcScalingMetric) { + this.vnfcScalingMetric = vnfcScalingMetric; + } + + @JsonProperty("vNicPerformanceArray") + public List<VNicPerformanceArray> getVNicPerformanceArray() { + return vNicPerformanceArray; + } + + @JsonProperty("vNicPerformanceArray") + public void setVNicPerformanceArray(List<VNicPerformanceArray> vNicPerformanceArray) { + this.vNicPerformanceArray = vNicPerformanceArray; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("measurementInterval", measurementInterval).append("measurementsForVfScalingVersion", measurementsForVfScalingVersion).append("additionalFields", additionalFields).append("additionalMeasurements", additionalMeasurements).append("additionalObjects", additionalObjects).append("codecUsageArray", codecUsageArray).append("concurrentSessions", concurrentSessions).append("configuredEntities", configuredEntities).append("cpuUsageArray", cpuUsageArray).append("diskUsageArray", diskUsageArray).append("featureUsageArray", featureUsageArray).append("filesystemUsageArray", filesystemUsageArray).append("latencyDistribution", latencyDistribution).append("meanRequestLatency", meanRequestLatency).append("memoryUsageArray", memoryUsageArray).append("numberOfMediaPortsInUse", numberOfMediaPortsInUse).append("requestRate", requestRate).append("vnfcScalingMetric", vnfcScalingMetric).append("vNicPerformanceArray", vNicPerformanceArray).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(requestRate).append(numberOfMediaPortsInUse).append(measurementInterval).append(diskUsageArray).append(additionalObjects).append(measurementsForVfScalingVersion).append(filesystemUsageArray).append(featureUsageArray).append(vNicPerformanceArray).append(vnfcScalingMetric).append(cpuUsageArray).append(additionalProperties).append(meanRequestLatency).append(additionalMeasurements).append(latencyDistribution).append(concurrentSessions).append(codecUsageArray).append(additionalFields).append(memoryUsageArray).append(configuredEntities).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof MeasurementsForVfScalingFields) == false) { + return false; + } + MeasurementsForVfScalingFields rhs = ((MeasurementsForVfScalingFields) other); + return new EqualsBuilder().append(requestRate, rhs.requestRate).append(numberOfMediaPortsInUse, rhs.numberOfMediaPortsInUse).append(measurementInterval, rhs.measurementInterval).append(diskUsageArray, rhs.diskUsageArray).append(additionalObjects, rhs.additionalObjects).append(measurementsForVfScalingVersion, rhs.measurementsForVfScalingVersion).append(filesystemUsageArray, rhs.filesystemUsageArray).append(featureUsageArray, rhs.featureUsageArray).append(vNicPerformanceArray, rhs.vNicPerformanceArray).append(vnfcScalingMetric, rhs.vnfcScalingMetric).append(cpuUsageArray, rhs.cpuUsageArray).append(additionalProperties, rhs.additionalProperties).append(meanRequestLatency, rhs.meanRequestLatency).append(additionalMeasurements, rhs.additionalMeasurements).append(latencyDistribution, rhs.latencyDistribution).append(concurrentSessions, rhs.concurrentSessions).append(codecUsageArray, rhs.codecUsageArray).append(additionalFields, rhs.additionalFields).append(memoryUsageArray, rhs.memoryUsageArray).append(configuredEntities, rhs.configuredEntities).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/MemoryUsageArray.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/MemoryUsageArray.java new file mode 100644 index 0000000..8ce16ae --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/MemoryUsageArray.java @@ -0,0 +1,178 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "memoryFree", + "memoryUsed", + "vmIdentifier", + "memoryBuffered", + "memoryCached", + "memoryConfigured", + "memorySlabRecl", + "memorySlabUnrecl" +}) +public class MemoryUsageArray { + + @JsonProperty("memoryFree") + private Double memoryFree; + @JsonProperty("memoryUsed") + private Double memoryUsed; + @JsonProperty("vmIdentifier") + private String vmIdentifier; + @JsonProperty("memoryBuffered") + private Double memoryBuffered; + @JsonProperty("memoryCached") + private Double memoryCached; + @JsonProperty("memoryConfigured") + private Double memoryConfigured; + @JsonProperty("memorySlabRecl") + private Double memorySlabRecl; + @JsonProperty("memorySlabUnrecl") + private Double memorySlabUnrecl; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("memoryFree") + public Double getMemoryFree() { + return memoryFree; + } + + @JsonProperty("memoryFree") + public void setMemoryFree(Double memoryFree) { + this.memoryFree = memoryFree; + } + + @JsonProperty("memoryUsed") + public Double getMemoryUsed() { + return memoryUsed; + } + + @JsonProperty("memoryUsed") + public void setMemoryUsed(Double memoryUsed) { + this.memoryUsed = memoryUsed; + } + + @JsonProperty("vmIdentifier") + public String getVmIdentifier() { + return vmIdentifier; + } + + @JsonProperty("vmIdentifier") + public void setVmIdentifier(String vmIdentifier) { + this.vmIdentifier = vmIdentifier; + } + + @JsonProperty("memoryBuffered") + public Double getMemoryBuffered() { + return memoryBuffered; + } + + @JsonProperty("memoryBuffered") + public void setMemoryBuffered(Double memoryBuffered) { + this.memoryBuffered = memoryBuffered; + } + + @JsonProperty("memoryCached") + public Double getMemoryCached() { + return memoryCached; + } + + @JsonProperty("memoryCached") + public void setMemoryCached(Double memoryCached) { + this.memoryCached = memoryCached; + } + + @JsonProperty("memoryConfigured") + public Double getMemoryConfigured() { + return memoryConfigured; + } + + @JsonProperty("memoryConfigured") + public void setMemoryConfigured(Double memoryConfigured) { + this.memoryConfigured = memoryConfigured; + } + + @JsonProperty("memorySlabRecl") + public Double getMemorySlabRecl() { + return memorySlabRecl; + } + + @JsonProperty("memorySlabRecl") + public void setMemorySlabRecl(Double memorySlabRecl) { + this.memorySlabRecl = memorySlabRecl; + } + + @JsonProperty("memorySlabUnrecl") + public Double getMemorySlabUnrecl() { + return memorySlabUnrecl; + } + + @JsonProperty("memorySlabUnrecl") + public void setMemorySlabUnrecl(Double memorySlabUnrecl) { + this.memorySlabUnrecl = memorySlabUnrecl; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("memoryFree", memoryFree).append("memoryUsed", memoryUsed).append("vmIdentifier", vmIdentifier).append("memoryBuffered", memoryBuffered).append("memoryCached", memoryCached).append("memoryConfigured", memoryConfigured).append("memorySlabRecl", memorySlabRecl).append("memorySlabUnrecl", memorySlabUnrecl).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(memorySlabUnrecl).append(memoryFree).append(memoryConfigured).append(additionalProperties).append(memorySlabRecl).append(memoryBuffered).append(vmIdentifier).append(memoryUsed).append(memoryCached).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof MemoryUsageArray) == false) { + return false; + } + MemoryUsageArray rhs = ((MemoryUsageArray) other); + return new EqualsBuilder().append(memorySlabUnrecl, rhs.memorySlabUnrecl).append(memoryFree, rhs.memoryFree).append(memoryConfigured, rhs.memoryConfigured).append(additionalProperties, rhs.additionalProperties).append(memorySlabRecl, rhs.memorySlabRecl).append(memoryBuffered, rhs.memoryBuffered).append(vmIdentifier, rhs.vmIdentifier).append(memoryUsed, rhs.memoryUsed).append(memoryCached, rhs.memoryCached).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/MobileFlowFields.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/MobileFlowFields.java new file mode 100644 index 0000000..7a19279 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/MobileFlowFields.java @@ -0,0 +1,504 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "flowDirection", + "gtpPerFlowMetrics", + "ipProtocolType", + "ipVersion", + "mobileFlowFieldsVersion", + "otherEndpointIpAddress", + "otherEndpointPort", + "reportingEndpointIpAddr", + "reportingEndpointPort", + "additionalFields", + "applicationType", + "appProtocolType", + "appProtocolVersion", + "cid", + "connectionType", + "ecgi", + "gtpProtocolType", + "gtpVersion", + "httpHeader", + "imei", + "imsi", + "lac", + "mcc", + "mnc", + "msisdn", + "otherFunctionalRole", + "rac", + "radioAccessTechnology", + "sac", + "samplingAlgorithm", + "tac", + "tunnelId", + "vlanId" +}) +public class MobileFlowFields { + + @JsonProperty("flowDirection") + private String flowDirection; + @JsonProperty("gtpPerFlowMetrics") + private GtpPerFlowMetrics gtpPerFlowMetrics; + @JsonProperty("ipProtocolType") + private String ipProtocolType; + @JsonProperty("ipVersion") + private String ipVersion; + @JsonProperty("mobileFlowFieldsVersion") + private Double mobileFlowFieldsVersion; + @JsonProperty("otherEndpointIpAddress") + private String otherEndpointIpAddress; + @JsonProperty("otherEndpointPort") + private Long otherEndpointPort; + @JsonProperty("reportingEndpointIpAddr") + private String reportingEndpointIpAddr; + @JsonProperty("reportingEndpointPort") + private Long reportingEndpointPort; + @JsonProperty("additionalFields") + private List<AdditionalField> additionalFields = null; + @JsonProperty("applicationType") + private String applicationType; + @JsonProperty("appProtocolType") + private String appProtocolType; + @JsonProperty("appProtocolVersion") + private String appProtocolVersion; + @JsonProperty("cid") + private String cid; + @JsonProperty("connectionType") + private String connectionType; + @JsonProperty("ecgi") + private String ecgi; + @JsonProperty("gtpProtocolType") + private String gtpProtocolType; + @JsonProperty("gtpVersion") + private String gtpVersion; + @JsonProperty("httpHeader") + private String httpHeader; + @JsonProperty("imei") + private String imei; + @JsonProperty("imsi") + private String imsi; + @JsonProperty("lac") + private String lac; + @JsonProperty("mcc") + private String mcc; + @JsonProperty("mnc") + private String mnc; + @JsonProperty("msisdn") + private String msisdn; + @JsonProperty("otherFunctionalRole") + private String otherFunctionalRole; + @JsonProperty("rac") + private String rac; + @JsonProperty("radioAccessTechnology") + private String radioAccessTechnology; + @JsonProperty("sac") + private String sac; + @JsonProperty("samplingAlgorithm") + private Long samplingAlgorithm; + @JsonProperty("tac") + private String tac; + @JsonProperty("tunnelId") + private String tunnelId; + @JsonProperty("vlanId") + private String vlanId; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("flowDirection") + public String getFlowDirection() { + return flowDirection; + } + + @JsonProperty("flowDirection") + public void setFlowDirection(String flowDirection) { + this.flowDirection = flowDirection; + } + + @JsonProperty("gtpPerFlowMetrics") + public GtpPerFlowMetrics getGtpPerFlowMetrics() { + return gtpPerFlowMetrics; + } + + @JsonProperty("gtpPerFlowMetrics") + public void setGtpPerFlowMetrics(GtpPerFlowMetrics gtpPerFlowMetrics) { + this.gtpPerFlowMetrics = gtpPerFlowMetrics; + } + + @JsonProperty("ipProtocolType") + public String getIpProtocolType() { + return ipProtocolType; + } + + @JsonProperty("ipProtocolType") + public void setIpProtocolType(String ipProtocolType) { + this.ipProtocolType = ipProtocolType; + } + + @JsonProperty("ipVersion") + public String getIpVersion() { + return ipVersion; + } + + @JsonProperty("ipVersion") + public void setIpVersion(String ipVersion) { + this.ipVersion = ipVersion; + } + + @JsonProperty("mobileFlowFieldsVersion") + public Double getMobileFlowFieldsVersion() { + return mobileFlowFieldsVersion; + } + + @JsonProperty("mobileFlowFieldsVersion") + public void setMobileFlowFieldsVersion(Double mobileFlowFieldsVersion) { + this.mobileFlowFieldsVersion = mobileFlowFieldsVersion; + } + + @JsonProperty("otherEndpointIpAddress") + public String getOtherEndpointIpAddress() { + return otherEndpointIpAddress; + } + + @JsonProperty("otherEndpointIpAddress") + public void setOtherEndpointIpAddress(String otherEndpointIpAddress) { + this.otherEndpointIpAddress = otherEndpointIpAddress; + } + + @JsonProperty("otherEndpointPort") + public Long getOtherEndpointPort() { + return otherEndpointPort; + } + + @JsonProperty("otherEndpointPort") + public void setOtherEndpointPort(Long otherEndpointPort) { + this.otherEndpointPort = otherEndpointPort; + } + + @JsonProperty("reportingEndpointIpAddr") + public String getReportingEndpointIpAddr() { + return reportingEndpointIpAddr; + } + + @JsonProperty("reportingEndpointIpAddr") + public void setReportingEndpointIpAddr(String reportingEndpointIpAddr) { + this.reportingEndpointIpAddr = reportingEndpointIpAddr; + } + + @JsonProperty("reportingEndpointPort") + public Long getReportingEndpointPort() { + return reportingEndpointPort; + } + + @JsonProperty("reportingEndpointPort") + public void setReportingEndpointPort(Long reportingEndpointPort) { + this.reportingEndpointPort = reportingEndpointPort; + } + + @JsonProperty("additionalFields") + public List<AdditionalField> getAdditionalFields() { + return additionalFields; + } + + @JsonProperty("additionalFields") + public void setAdditionalFields(List<AdditionalField> additionalFields) { + this.additionalFields = additionalFields; + } + + @JsonProperty("applicationType") + public String getApplicationType() { + return applicationType; + } + + @JsonProperty("applicationType") + public void setApplicationType(String applicationType) { + this.applicationType = applicationType; + } + + @JsonProperty("appProtocolType") + public String getAppProtocolType() { + return appProtocolType; + } + + @JsonProperty("appProtocolType") + public void setAppProtocolType(String appProtocolType) { + this.appProtocolType = appProtocolType; + } + + @JsonProperty("appProtocolVersion") + public String getAppProtocolVersion() { + return appProtocolVersion; + } + + @JsonProperty("appProtocolVersion") + public void setAppProtocolVersion(String appProtocolVersion) { + this.appProtocolVersion = appProtocolVersion; + } + + @JsonProperty("cid") + public String getCid() { + return cid; + } + + @JsonProperty("cid") + public void setCid(String cid) { + this.cid = cid; + } + + @JsonProperty("connectionType") + public String getConnectionType() { + return connectionType; + } + + @JsonProperty("connectionType") + public void setConnectionType(String connectionType) { + this.connectionType = connectionType; + } + + @JsonProperty("ecgi") + public String getEcgi() { + return ecgi; + } + + @JsonProperty("ecgi") + public void setEcgi(String ecgi) { + this.ecgi = ecgi; + } + + @JsonProperty("gtpProtocolType") + public String getGtpProtocolType() { + return gtpProtocolType; + } + + @JsonProperty("gtpProtocolType") + public void setGtpProtocolType(String gtpProtocolType) { + this.gtpProtocolType = gtpProtocolType; + } + + @JsonProperty("gtpVersion") + public String getGtpVersion() { + return gtpVersion; + } + + @JsonProperty("gtpVersion") + public void setGtpVersion(String gtpVersion) { + this.gtpVersion = gtpVersion; + } + + @JsonProperty("httpHeader") + public String getHttpHeader() { + return httpHeader; + } + + @JsonProperty("httpHeader") + public void setHttpHeader(String httpHeader) { + this.httpHeader = httpHeader; + } + + @JsonProperty("imei") + public String getImei() { + return imei; + } + + @JsonProperty("imei") + public void setImei(String imei) { + this.imei = imei; + } + + @JsonProperty("imsi") + public String getImsi() { + return imsi; + } + + @JsonProperty("imsi") + public void setImsi(String imsi) { + this.imsi = imsi; + } + + @JsonProperty("lac") + public String getLac() { + return lac; + } + + @JsonProperty("lac") + public void setLac(String lac) { + this.lac = lac; + } + + @JsonProperty("mcc") + public String getMcc() { + return mcc; + } + + @JsonProperty("mcc") + public void setMcc(String mcc) { + this.mcc = mcc; + } + + @JsonProperty("mnc") + public String getMnc() { + return mnc; + } + + @JsonProperty("mnc") + public void setMnc(String mnc) { + this.mnc = mnc; + } + + @JsonProperty("msisdn") + public String getMsisdn() { + return msisdn; + } + + @JsonProperty("msisdn") + public void setMsisdn(String msisdn) { + this.msisdn = msisdn; + } + + @JsonProperty("otherFunctionalRole") + public String getOtherFunctionalRole() { + return otherFunctionalRole; + } + + @JsonProperty("otherFunctionalRole") + public void setOtherFunctionalRole(String otherFunctionalRole) { + this.otherFunctionalRole = otherFunctionalRole; + } + + @JsonProperty("rac") + public String getRac() { + return rac; + } + + @JsonProperty("rac") + public void setRac(String rac) { + this.rac = rac; + } + + @JsonProperty("radioAccessTechnology") + public String getRadioAccessTechnology() { + return radioAccessTechnology; + } + + @JsonProperty("radioAccessTechnology") + public void setRadioAccessTechnology(String radioAccessTechnology) { + this.radioAccessTechnology = radioAccessTechnology; + } + + @JsonProperty("sac") + public String getSac() { + return sac; + } + + @JsonProperty("sac") + public void setSac(String sac) { + this.sac = sac; + } + + @JsonProperty("samplingAlgorithm") + public Long getSamplingAlgorithm() { + return samplingAlgorithm; + } + + @JsonProperty("samplingAlgorithm") + public void setSamplingAlgorithm(Long samplingAlgorithm) { + this.samplingAlgorithm = samplingAlgorithm; + } + + @JsonProperty("tac") + public String getTac() { + return tac; + } + + @JsonProperty("tac") + public void setTac(String tac) { + this.tac = tac; + } + + @JsonProperty("tunnelId") + public String getTunnelId() { + return tunnelId; + } + + @JsonProperty("tunnelId") + public void setTunnelId(String tunnelId) { + this.tunnelId = tunnelId; + } + + @JsonProperty("vlanId") + public String getVlanId() { + return vlanId; + } + + @JsonProperty("vlanId") + public void setVlanId(String vlanId) { + this.vlanId = vlanId; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("flowDirection", flowDirection).append("gtpPerFlowMetrics", gtpPerFlowMetrics).append("ipProtocolType", ipProtocolType).append("ipVersion", ipVersion).append("mobileFlowFieldsVersion", mobileFlowFieldsVersion).append("otherEndpointIpAddress", otherEndpointIpAddress).append("otherEndpointPort", otherEndpointPort).append("reportingEndpointIpAddr", reportingEndpointIpAddr).append("reportingEndpointPort", reportingEndpointPort).append("additionalFields", additionalFields).append("applicationType", applicationType).append("appProtocolType", appProtocolType).append("appProtocolVersion", appProtocolVersion).append("cid", cid).append("connectionType", connectionType).append("ecgi", ecgi).append("gtpProtocolType", gtpProtocolType).append("gtpVersion", gtpVersion).append("httpHeader", httpHeader).append("imei", imei).append("imsi", imsi).append("lac", lac).append("mcc", mcc).append("mnc", mnc).append("msisdn", msisdn).append("otherFunctionalRole", otherFunctionalRole).append("rac", rac).append("radioAccessTechnology", radioAccessTechnology).append("sac", sac).append("samplingAlgorithm", samplingAlgorithm).append("tac", tac).append("tunnelId", tunnelId).append("vlanId", vlanId).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(sac).append(mcc).append(samplingAlgorithm).append(tac).append(applicationType).append(gtpPerFlowMetrics).append(vlanId).append(radioAccessTechnology).append(lac).append(flowDirection).append(httpHeader).append(mnc).append(additionalFields).append(reportingEndpointIpAddr).append(appProtocolVersion).append(msisdn).append(tunnelId).append(imei).append(ipVersion).append(gtpProtocolType).append(reportingEndpointPort).append(otherEndpointPort).append(connectionType).append(ecgi).append(gtpVersion).append(cid).append(ipProtocolType).append(mobileFlowFieldsVersion).append(additionalProperties).append(imsi).append(otherFunctionalRole).append(otherEndpointIpAddress).append(appProtocolType).append(rac).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof MobileFlowFields) == false) { + return false; + } + MobileFlowFields rhs = ((MobileFlowFields) other); + return new EqualsBuilder().append(sac, rhs.sac).append(mcc, rhs.mcc).append(samplingAlgorithm, rhs.samplingAlgorithm).append(tac, rhs.tac).append(applicationType, rhs.applicationType).append(gtpPerFlowMetrics, rhs.gtpPerFlowMetrics).append(vlanId, rhs.vlanId).append(radioAccessTechnology, rhs.radioAccessTechnology).append(lac, rhs.lac).append(flowDirection, rhs.flowDirection).append(httpHeader, rhs.httpHeader).append(mnc, rhs.mnc).append(additionalFields, rhs.additionalFields).append(reportingEndpointIpAddr, rhs.reportingEndpointIpAddr).append(appProtocolVersion, rhs.appProtocolVersion).append(msisdn, rhs.msisdn).append(tunnelId, rhs.tunnelId).append(imei, rhs.imei).append(ipVersion, rhs.ipVersion).append(gtpProtocolType, rhs.gtpProtocolType).append(reportingEndpointPort, rhs.reportingEndpointPort).append(otherEndpointPort, rhs.otherEndpointPort).append(connectionType, rhs.connectionType).append(ecgi, rhs.ecgi).append(gtpVersion, rhs.gtpVersion).append(cid, rhs.cid).append(ipProtocolType, rhs.ipProtocolType).append(mobileFlowFieldsVersion, rhs.mobileFlowFieldsVersion).append(additionalProperties, rhs.additionalProperties).append(imsi, rhs.imsi).append(otherFunctionalRole, rhs.otherFunctionalRole).append(otherEndpointIpAddress, rhs.otherEndpointIpAddress).append(appProtocolType, rhs.appProtocolType).append(rac, rhs.rac).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/NameValuePair.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/NameValuePair.java new file mode 100644 index 0000000..ec42ccd --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/NameValuePair.java @@ -0,0 +1,100 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "name", + "value" +}) +public class NameValuePair { + + @JsonProperty("name") + private String name; + @JsonProperty("value") + private String value; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("name") + public String getName() { + return name; + } + + @JsonProperty("name") + public void setName(String name) { + this.name = name; + } + + @JsonProperty("value") + public String getValue() { + return value; + } + + @JsonProperty("value") + public void setValue(String value) { + this.value = value; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("name", name).append("value", value).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(additionalProperties).append(name).append(value).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof NameValuePair) == false) { + return false; + } + NameValuePair rhs = ((NameValuePair) other); + return new EqualsBuilder().append(additionalProperties, rhs.additionalProperties).append(name, rhs.name).append(value, rhs.value).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ObjectInstance.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ObjectInstance.java new file mode 100644 index 0000000..e277614 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ObjectInstance.java @@ -0,0 +1,114 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "objectInstance", + "objectInstanceEpochMicrosec", + "objectKeys" +}) +public class ObjectInstance { + + @JsonProperty("objectInstance") + private ObjectInstance_ objectInstance; + @JsonProperty("objectInstanceEpochMicrosec") + private Double objectInstanceEpochMicrosec; + @JsonProperty("objectKeys") + private List<ObjectKey> objectKeys = null; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("objectInstance") + public ObjectInstance_ getObjectInstance() { + return objectInstance; + } + + @JsonProperty("objectInstance") + public void setObjectInstance(ObjectInstance_ objectInstance) { + this.objectInstance = objectInstance; + } + + @JsonProperty("objectInstanceEpochMicrosec") + public Double getObjectInstanceEpochMicrosec() { + return objectInstanceEpochMicrosec; + } + + @JsonProperty("objectInstanceEpochMicrosec") + public void setObjectInstanceEpochMicrosec(Double objectInstanceEpochMicrosec) { + this.objectInstanceEpochMicrosec = objectInstanceEpochMicrosec; + } + + @JsonProperty("objectKeys") + public List<ObjectKey> getObjectKeys() { + return objectKeys; + } + + @JsonProperty("objectKeys") + public void setObjectKeys(List<ObjectKey> objectKeys) { + this.objectKeys = objectKeys; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("objectInstance", objectInstance).append("objectInstanceEpochMicrosec", objectInstanceEpochMicrosec).append("objectKeys", objectKeys).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(objectInstanceEpochMicrosec).append(additionalProperties).append(objectInstance).append(objectKeys).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof ObjectInstance) == false) { + return false; + } + ObjectInstance rhs = ((ObjectInstance) other); + return new EqualsBuilder().append(objectInstanceEpochMicrosec, rhs.objectInstanceEpochMicrosec).append(additionalProperties, rhs.additionalProperties).append(objectInstance, rhs.objectInstance).append(objectKeys, rhs.objectKeys).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ObjectInstance_.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ObjectInstance_.java new file mode 100644 index 0000000..ec01aba --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ObjectInstance_.java @@ -0,0 +1,74 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + +}) +public class ObjectInstance_ { + + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(additionalProperties).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof ObjectInstance_) == false) { + return false; + } + ObjectInstance_ rhs = ((ObjectInstance_) other); + return new EqualsBuilder().append(additionalProperties, rhs.additionalProperties).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ObjectKey.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ObjectKey.java new file mode 100644 index 0000000..bc2ed40 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ObjectKey.java @@ -0,0 +1,113 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "keyName", + "keyOrder", + "keyValue" +}) +public class ObjectKey { + + @JsonProperty("keyName") + private String keyName; + @JsonProperty("keyOrder") + private Long keyOrder; + @JsonProperty("keyValue") + private String keyValue; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("keyName") + public String getKeyName() { + return keyName; + } + + @JsonProperty("keyName") + public void setKeyName(String keyName) { + this.keyName = keyName; + } + + @JsonProperty("keyOrder") + public Long getKeyOrder() { + return keyOrder; + } + + @JsonProperty("keyOrder") + public void setKeyOrder(Long keyOrder) { + this.keyOrder = keyOrder; + } + + @JsonProperty("keyValue") + public String getKeyValue() { + return keyValue; + } + + @JsonProperty("keyValue") + public void setKeyValue(String keyValue) { + this.keyValue = keyValue; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("keyName", keyName).append("keyOrder", keyOrder).append("keyValue", keyValue).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(keyName).append(additionalProperties).append(keyOrder).append(keyValue).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof ObjectKey) == false) { + return false; + } + ObjectKey rhs = ((ObjectKey) other); + return new EqualsBuilder().append(keyName, rhs.keyName).append(additionalProperties, rhs.additionalProperties).append(keyOrder, rhs.keyOrder).append(keyValue, rhs.keyValue).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/OtherFields.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/OtherFields.java new file mode 100644 index 0000000..d5d01ff --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/OtherFields.java @@ -0,0 +1,127 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "otherFieldsVersion", + "hashOfNameValuePairArrays", + "jsonObjects", + "nameValuePairs" +}) +public class OtherFields { + + @JsonProperty("otherFieldsVersion") + private Double otherFieldsVersion; + @JsonProperty("hashOfNameValuePairArrays") + private List<HashOfNameValuePairArray> hashOfNameValuePairArrays = null; + @JsonProperty("jsonObjects") + private List<JsonObject> jsonObjects = null; + @JsonProperty("nameValuePairs") + private List<NameValuePair> nameValuePairs = null; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("otherFieldsVersion") + public Double getOtherFieldsVersion() { + return otherFieldsVersion; + } + + @JsonProperty("otherFieldsVersion") + public void setOtherFieldsVersion(Double otherFieldsVersion) { + this.otherFieldsVersion = otherFieldsVersion; + } + + @JsonProperty("hashOfNameValuePairArrays") + public List<HashOfNameValuePairArray> getHashOfNameValuePairArrays() { + return hashOfNameValuePairArrays; + } + + @JsonProperty("hashOfNameValuePairArrays") + public void setHashOfNameValuePairArrays(List<HashOfNameValuePairArray> hashOfNameValuePairArrays) { + this.hashOfNameValuePairArrays = hashOfNameValuePairArrays; + } + + @JsonProperty("jsonObjects") + public List<JsonObject> getJsonObjects() { + return jsonObjects; + } + + @JsonProperty("jsonObjects") + public void setJsonObjects(List<JsonObject> jsonObjects) { + this.jsonObjects = jsonObjects; + } + + @JsonProperty("nameValuePairs") + public List<NameValuePair> getNameValuePairs() { + return nameValuePairs; + } + + @JsonProperty("nameValuePairs") + public void setNameValuePairs(List<NameValuePair> nameValuePairs) { + this.nameValuePairs = nameValuePairs; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("otherFieldsVersion", otherFieldsVersion).append("hashOfNameValuePairArrays", hashOfNameValuePairArrays).append("jsonObjects", jsonObjects).append("nameValuePairs", nameValuePairs).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(nameValuePairs).append(hashOfNameValuePairArrays).append(additionalProperties).append(jsonObjects).append(otherFieldsVersion).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof OtherFields) == false) { + return false; + } + OtherFields rhs = ((OtherFields) other); + return new EqualsBuilder().append(nameValuePairs, rhs.nameValuePairs).append(hashOfNameValuePairArrays, rhs.hashOfNameValuePairArrays).append(additionalProperties, rhs.additionalProperties).append(jsonObjects, rhs.jsonObjects).append(otherFieldsVersion, rhs.otherFieldsVersion).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/SipSignalingFields.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/SipSignalingFields.java new file mode 100644 index 0000000..2eb2b6a --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/SipSignalingFields.java @@ -0,0 +1,205 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "correlator", + "localIpAddress", + "localPort", + "remoteIpAddress", + "remotePort", + "sipSignalingFieldsVersion", + "vendorVnfNameFields", + "additionalInformation", + "compressedSip", + "summarySip" +}) +public class SipSignalingFields { + + @JsonProperty("correlator") + private String correlator; + @JsonProperty("localIpAddress") + private String localIpAddress; + @JsonProperty("localPort") + private String localPort; + @JsonProperty("remoteIpAddress") + private String remoteIpAddress; + @JsonProperty("remotePort") + private String remotePort; + @JsonProperty("sipSignalingFieldsVersion") + private Double sipSignalingFieldsVersion; + @JsonProperty("vendorVnfNameFields") + private VendorVnfNameFields vendorVnfNameFields; + @JsonProperty("additionalInformation") + private List<AdditionalInformation> additionalInformation = null; + @JsonProperty("compressedSip") + private String compressedSip; + @JsonProperty("summarySip") + private String summarySip; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("correlator") + public String getCorrelator() { + return correlator; + } + + @JsonProperty("correlator") + public void setCorrelator(String correlator) { + this.correlator = correlator; + } + + @JsonProperty("localIpAddress") + public String getLocalIpAddress() { + return localIpAddress; + } + + @JsonProperty("localIpAddress") + public void setLocalIpAddress(String localIpAddress) { + this.localIpAddress = localIpAddress; + } + + @JsonProperty("localPort") + public String getLocalPort() { + return localPort; + } + + @JsonProperty("localPort") + public void setLocalPort(String localPort) { + this.localPort = localPort; + } + + @JsonProperty("remoteIpAddress") + public String getRemoteIpAddress() { + return remoteIpAddress; + } + + @JsonProperty("remoteIpAddress") + public void setRemoteIpAddress(String remoteIpAddress) { + this.remoteIpAddress = remoteIpAddress; + } + + @JsonProperty("remotePort") + public String getRemotePort() { + return remotePort; + } + + @JsonProperty("remotePort") + public void setRemotePort(String remotePort) { + this.remotePort = remotePort; + } + + @JsonProperty("sipSignalingFieldsVersion") + public Double getSipSignalingFieldsVersion() { + return sipSignalingFieldsVersion; + } + + @JsonProperty("sipSignalingFieldsVersion") + public void setSipSignalingFieldsVersion(Double sipSignalingFieldsVersion) { + this.sipSignalingFieldsVersion = sipSignalingFieldsVersion; + } + + @JsonProperty("vendorVnfNameFields") + public VendorVnfNameFields getVendorVnfNameFields() { + return vendorVnfNameFields; + } + + @JsonProperty("vendorVnfNameFields") + public void setVendorVnfNameFields(VendorVnfNameFields vendorVnfNameFields) { + this.vendorVnfNameFields = vendorVnfNameFields; + } + + @JsonProperty("additionalInformation") + public List<AdditionalInformation> getAdditionalInformation() { + return additionalInformation; + } + + @JsonProperty("additionalInformation") + public void setAdditionalInformation(List<AdditionalInformation> additionalInformation) { + this.additionalInformation = additionalInformation; + } + + @JsonProperty("compressedSip") + public String getCompressedSip() { + return compressedSip; + } + + @JsonProperty("compressedSip") + public void setCompressedSip(String compressedSip) { + this.compressedSip = compressedSip; + } + + @JsonProperty("summarySip") + public String getSummarySip() { + return summarySip; + } + + @JsonProperty("summarySip") + public void setSummarySip(String summarySip) { + this.summarySip = summarySip; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("correlator", correlator).append("localIpAddress", localIpAddress).append("localPort", localPort).append("remoteIpAddress", remoteIpAddress).append("remotePort", remotePort).append("sipSignalingFieldsVersion", sipSignalingFieldsVersion).append("vendorVnfNameFields", vendorVnfNameFields).append("additionalInformation", additionalInformation).append("compressedSip", compressedSip).append("summarySip", summarySip).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(vendorVnfNameFields).append(correlator).append(additionalProperties).append(remoteIpAddress).append(sipSignalingFieldsVersion).append(localIpAddress).append(summarySip).append(remotePort).append(localPort).append(additionalInformation).append(compressedSip).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof SipSignalingFields) == false) { + return false; + } + SipSignalingFields rhs = ((SipSignalingFields) other); + return new EqualsBuilder().append(vendorVnfNameFields, rhs.vendorVnfNameFields).append(correlator, rhs.correlator).append(additionalProperties, rhs.additionalProperties).append(remoteIpAddress, rhs.remoteIpAddress).append(sipSignalingFieldsVersion, rhs.sipSignalingFieldsVersion).append(localIpAddress, rhs.localIpAddress).append(summarySip, rhs.summarySip).append(remotePort, rhs.remotePort).append(localPort, rhs.localPort).append(additionalInformation, rhs.additionalInformation).append(compressedSip, rhs.compressedSip).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/StateChangeFields.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/StateChangeFields.java new file mode 100644 index 0000000..993b75b --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/StateChangeFields.java @@ -0,0 +1,141 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; +import org.apache.commons.lang.builder.EqualsBuilder; +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.commons.lang.builder.ToStringBuilder; +import org.onap.dcaegen2.ves.domain.AdditionalField; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "newState", + "oldState", + "stateChangeFieldsVersion", + "stateInterface", + "additionalFields" +}) +public class StateChangeFields { + + @JsonProperty("newState") + private String newState; + @JsonProperty("oldState") + private String oldState; + @JsonProperty("stateChangeFieldsVersion") + private Double stateChangeFieldsVersion; + @JsonProperty("stateInterface") + private String stateInterface; + @JsonProperty("additionalFields") + private List<AdditionalField> additionalFields = null; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("newState") + public String getNewState() { + return newState; + } + + @JsonProperty("newState") + public void setNewState(String newState) { + this.newState = newState; + } + + @JsonProperty("oldState") + public String getOldState() { + return oldState; + } + + @JsonProperty("oldState") + public void setOldState(String oldState) { + this.oldState = oldState; + } + + @JsonProperty("stateChangeFieldsVersion") + public Double getStateChangeFieldsVersion() { + return stateChangeFieldsVersion; + } + + @JsonProperty("stateChangeFieldsVersion") + public void setStateChangeFieldsVersion(Double stateChangeFieldsVersion) { + this.stateChangeFieldsVersion = stateChangeFieldsVersion; + } + + @JsonProperty("stateInterface") + public String getStateInterface() { + return stateInterface; + } + + @JsonProperty("stateInterface") + public void setStateInterface(String stateInterface) { + this.stateInterface = stateInterface; + } + + @JsonProperty("additionalFields") + public List<AdditionalField> getAdditionalFields() { + return additionalFields; + } + + @JsonProperty("additionalFields") + public void setAdditionalFields(List<AdditionalField> additionalFields) { + this.additionalFields = additionalFields; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + @Override + public String toString() { + return new ToStringBuilder(this).append("newState", newState).append("oldState", oldState).append("stateChangeFieldsVersion", stateChangeFieldsVersion).append("stateInterface", stateInterface).append("additionalFields", additionalFields).append("additionalProperties", additionalProperties).toString(); + } + + @Override + public int hashCode() { + return new HashCodeBuilder().append(oldState).append(stateInterface).append(additionalProperties).append(additionalFields).append(stateChangeFieldsVersion).append(newState).toHashCode(); + } + + @Override + public boolean equals(Object other) { + if (other == this) { + return true; + } + if ((other instanceof StateChangeFields) == false) { + return false; + } + StateChangeFields rhs = ((StateChangeFields) other); + return new EqualsBuilder().append(oldState, rhs.oldState).append(stateInterface, rhs.stateInterface).append(additionalProperties, rhs.additionalProperties).append(additionalFields, rhs.additionalFields).append(stateChangeFieldsVersion, rhs.stateChangeFieldsVersion).append(newState, rhs.newState).isEquals(); + } + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/SyslogFields.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/SyslogFields.java new file mode 100644 index 0000000..7ce1a21 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/SyslogFields.java @@ -0,0 +1,234 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; + + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "eventSourceType", + "syslogFieldsVersion", + "syslogMsg", + "syslogTag", + "additionalFields", + "eventSourceHost", + "syslogFacility", + "syslogPri", + "syslogProc", + "syslogProcId", + "syslogSData", + "syslogSdId", + "syslogSev", + "syslogVer" +}) +public class SyslogFields { + + @JsonProperty("eventSourceType") + private String eventSourceType; + @JsonProperty("syslogFieldsVersion") + private Double syslogFieldsVersion; + @JsonProperty("syslogMsg") + private String syslogMsg; + @JsonProperty("syslogTag") + private String syslogTag; + @JsonProperty("additionalFields") + private String additionalFields; + @JsonProperty("eventSourceHost") + private String eventSourceHost; + @JsonProperty("syslogFacility") + private Long syslogFacility; + @JsonProperty("syslogPri") + private Long syslogPri; + @JsonProperty("syslogProc") + private String syslogProc; + @JsonProperty("syslogProcId") + private Double syslogProcId; + @JsonProperty("syslogSData") + private String syslogSData; + @JsonProperty("syslogSdId") + private String syslogSdId; + @JsonProperty("syslogSev") + private String syslogSev; + @JsonProperty("syslogVer") + private Double syslogVer; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("eventSourceType") + public String getEventSourceType() { + return eventSourceType; + } + + @JsonProperty("eventSourceType") + public void setEventSourceType(String eventSourceType) { + this.eventSourceType = eventSourceType; + } + + @JsonProperty("syslogFieldsVersion") + public Double getSyslogFieldsVersion() { + return syslogFieldsVersion; + } + + @JsonProperty("syslogFieldsVersion") + public void setSyslogFieldsVersion(Double syslogFieldsVersion) { + this.syslogFieldsVersion = syslogFieldsVersion; + } + + @JsonProperty("syslogMsg") + public String getSyslogMsg() { + return syslogMsg; + } + + @JsonProperty("syslogMsg") + public void setSyslogMsg(String syslogMsg) { + this.syslogMsg = syslogMsg; + } + + @JsonProperty("syslogTag") + public String getSyslogTag() { + return syslogTag; + } + + @JsonProperty("syslogTag") + public void setSyslogTag(String syslogTag) { + this.syslogTag = syslogTag; + } + + @JsonProperty("additionalFields") + public String getAdditionalFields() { + return additionalFields; + } + + @JsonProperty("additionalFields") + public void setAdditionalFields(String additionalFields) { + this.additionalFields = additionalFields; + } + + @JsonProperty("eventSourceHost") + public String getEventSourceHost() { + return eventSourceHost; + } + + @JsonProperty("eventSourceHost") + public void setEventSourceHost(String eventSourceHost) { + this.eventSourceHost = eventSourceHost; + } + + @JsonProperty("syslogFacility") + public Long getSyslogFacility() { + return syslogFacility; + } + + @JsonProperty("syslogFacility") + public void setSyslogFacility(Long syslogFacility) { + this.syslogFacility = syslogFacility; + } + + @JsonProperty("syslogPri") + public Long getSyslogPri() { + return syslogPri; + } + + @JsonProperty("syslogPri") + public void setSyslogPri(Long syslogPri) { + this.syslogPri = syslogPri; + } + + @JsonProperty("syslogProc") + public String getSyslogProc() { + return syslogProc; + } + + @JsonProperty("syslogProc") + public void setSyslogProc(String syslogProc) { + this.syslogProc = syslogProc; + } + + @JsonProperty("syslogProcId") + public Double getSyslogProcId() { + return syslogProcId; + } + + @JsonProperty("syslogProcId") + public void setSyslogProcId(Double syslogProcId) { + this.syslogProcId = syslogProcId; + } + + @JsonProperty("syslogSData") + public String getSyslogSData() { + return syslogSData; + } + + @JsonProperty("syslogSData") + public void setSyslogSData(String syslogSData) { + this.syslogSData = syslogSData; + } + + @JsonProperty("syslogSdId") + public String getSyslogSdId() { + return syslogSdId; + } + + @JsonProperty("syslogSdId") + public void setSyslogSdId(String syslogSdId) { + this.syslogSdId = syslogSdId; + } + + @JsonProperty("syslogSev") + public String getSyslogSev() { + return syslogSev; + } + + @JsonProperty("syslogSev") + public void setSyslogSev(String syslogSev) { + this.syslogSev = syslogSev; + } + + @JsonProperty("syslogVer") + public Double getSyslogVer() { + return syslogVer; + } + + @JsonProperty("syslogVer") + public void setSyslogVer(Double syslogVer) { + this.syslogVer = syslogVer; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ThresholdCrossingAlertFields.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ThresholdCrossingAlertFields.java new file mode 100644 index 0000000..3c42955 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/ThresholdCrossingAlertFields.java @@ -0,0 +1,260 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "additionalParameters", + "alertAction", + "alertDescription", + "alertType", + "collectionTimestamp", + "eventSeverity", + "eventStartTimestamp", + "thresholdCrossingFieldsVersion", + "additionalFields", + "alertValue", + "associatedAlertIdList", + "dataCollector", + "elementType", + "interfaceName", + "networkService", + "possibleRootCause" +}) +public class ThresholdCrossingAlertFields { + + @JsonProperty("additionalParameters") + private List<AdditionalParameter> additionalParameters = null; + @JsonProperty("alertAction") + private String alertAction; + @JsonProperty("alertDescription") + private String alertDescription; + @JsonProperty("alertType") + private String alertType; + @JsonProperty("collectionTimestamp") + private String collectionTimestamp; + @JsonProperty("eventSeverity") + private String eventSeverity; + @JsonProperty("eventStartTimestamp") + private String eventStartTimestamp; + @JsonProperty("thresholdCrossingFieldsVersion") + private Double thresholdCrossingFieldsVersion; + @JsonProperty("additionalFields") + private List<AdditionalField> additionalFields = null; + @JsonProperty("alertValue") + private String alertValue; + @JsonProperty("associatedAlertIdList") + private List<String> associatedAlertIdList = null; + @JsonProperty("dataCollector") + private String dataCollector; + @JsonProperty("elementType") + private String elementType; + @JsonProperty("interfaceName") + private String interfaceName; + @JsonProperty("networkService") + private String networkService; + @JsonProperty("possibleRootCause") + private String possibleRootCause; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("additionalParameters") + public List<AdditionalParameter> getAdditionalParameters() { + return additionalParameters; + } + + @JsonProperty("additionalParameters") + public void setAdditionalParameters(List<AdditionalParameter> additionalParameters) { + this.additionalParameters = additionalParameters; + } + + @JsonProperty("alertAction") + public String getAlertAction() { + return alertAction; + } + + @JsonProperty("alertAction") + public void setAlertAction(String alertAction) { + this.alertAction = alertAction; + } + + @JsonProperty("alertDescription") + public String getAlertDescription() { + return alertDescription; + } + + @JsonProperty("alertDescription") + public void setAlertDescription(String alertDescription) { + this.alertDescription = alertDescription; + } + + @JsonProperty("alertType") + public String getAlertType() { + return alertType; + } + + @JsonProperty("alertType") + public void setAlertType(String alertType) { + this.alertType = alertType; + } + + @JsonProperty("collectionTimestamp") + public String getCollectionTimestamp() { + return collectionTimestamp; + } + + @JsonProperty("collectionTimestamp") + public void setCollectionTimestamp(String collectionTimestamp) { + this.collectionTimestamp = collectionTimestamp; + } + + @JsonProperty("eventSeverity") + public String getEventSeverity() { + return eventSeverity; + } + + @JsonProperty("eventSeverity") + public void setEventSeverity(String eventSeverity) { + this.eventSeverity = eventSeverity; + } + + @JsonProperty("eventStartTimestamp") + public String getEventStartTimestamp() { + return eventStartTimestamp; + } + + @JsonProperty("eventStartTimestamp") + public void setEventStartTimestamp(String eventStartTimestamp) { + this.eventStartTimestamp = eventStartTimestamp; + } + + @JsonProperty("thresholdCrossingFieldsVersion") + public Double getThresholdCrossingFieldsVersion() { + return thresholdCrossingFieldsVersion; + } + + @JsonProperty("thresholdCrossingFieldsVersion") + public void setThresholdCrossingFieldsVersion(Double thresholdCrossingFieldsVersion) { + this.thresholdCrossingFieldsVersion = thresholdCrossingFieldsVersion; + } + + @JsonProperty("additionalFields") + public List<AdditionalField> getAdditionalFields() { + return additionalFields; + } + + @JsonProperty("additionalFields") + public void setAdditionalFields(List<AdditionalField> additionalFields) { + this.additionalFields = additionalFields; + } + + @JsonProperty("alertValue") + public String getAlertValue() { + return alertValue; + } + + @JsonProperty("alertValue") + public void setAlertValue(String alertValue) { + this.alertValue = alertValue; + } + + @JsonProperty("associatedAlertIdList") + public List<String> getAssociatedAlertIdList() { + return associatedAlertIdList; + } + + @JsonProperty("associatedAlertIdList") + public void setAssociatedAlertIdList(List<String> associatedAlertIdList) { + this.associatedAlertIdList = associatedAlertIdList; + } + + @JsonProperty("dataCollector") + public String getDataCollector() { + return dataCollector; + } + + @JsonProperty("dataCollector") + public void setDataCollector(String dataCollector) { + this.dataCollector = dataCollector; + } + + @JsonProperty("elementType") + public String getElementType() { + return elementType; + } + + @JsonProperty("elementType") + public void setElementType(String elementType) { + this.elementType = elementType; + } + + @JsonProperty("interfaceName") + public String getInterfaceName() { + return interfaceName; + } + + @JsonProperty("interfaceName") + public void setInterfaceName(String interfaceName) { + this.interfaceName = interfaceName; + } + + @JsonProperty("networkService") + public String getNetworkService() { + return networkService; + } + + @JsonProperty("networkService") + public void setNetworkService(String networkService) { + this.networkService = networkService; + } + + @JsonProperty("possibleRootCause") + public String getPossibleRootCause() { + return possibleRootCause; + } + + @JsonProperty("possibleRootCause") + public void setPossibleRootCause(String possibleRootCause) { + this.possibleRootCause = possibleRootCause; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/VNicPerformanceArray.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/VNicPerformanceArray.java new file mode 100644 index 0000000..70415b4 --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/VNicPerformanceArray.java @@ -0,0 +1,441 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "valuesAreSuspect", + "vNicIdentifier", + "receivedBroadcastPacketsAccumulated", + "receivedBroadcastPacketsDelta", + "receivedDiscardedPacketsAccumulated", + "receivedDiscardedPacketsDelta", + "receivedErrorPacketsAccumulated", + "receivedErrorPacketsDelta", + "receivedMulticastPacketsAccumulated", + "receivedMulticastPacketsDelta", + "receivedOctetsAccumulated", + "receivedOctetsDelta", + "receivedTotalPacketsAccumulated", + "receivedTotalPacketsDelta", + "receivedUnicastPacketsAccumulated", + "receivedUnicastPacketsDelta", + "transmittedBroadcastPacketsAccumulated", + "transmittedBroadcastPacketsDelta", + "transmittedDiscardedPacketsAccumulated", + "transmittedDiscardedPacketsDelta", + "transmittedErrorPacketsAccumulated", + "transmittedErrorPacketsDelta", + "transmittedMulticastPacketsAccumulated", + "transmittedMulticastPacketsDelta", + "transmittedOctetsAccumulated", + "transmittedOctetsDelta", + "transmittedTotalPacketsAccumulated", + "transmittedTotalPacketsDelta", + "transmittedUnicastPacketsAccumulated", + "transmittedUnicastPacketsDelta" +}) +public class VNicPerformanceArray { + + @JsonProperty("valuesAreSuspect") + private String valuesAreSuspect; + @JsonProperty("vNicIdentifier") + private String vNicIdentifier; + @JsonProperty("receivedBroadcastPacketsAccumulated") + private Double receivedBroadcastPacketsAccumulated; + @JsonProperty("receivedBroadcastPacketsDelta") + private Double receivedBroadcastPacketsDelta; + @JsonProperty("receivedDiscardedPacketsAccumulated") + private Double receivedDiscardedPacketsAccumulated; + @JsonProperty("receivedDiscardedPacketsDelta") + private Double receivedDiscardedPacketsDelta; + @JsonProperty("receivedErrorPacketsAccumulated") + private Double receivedErrorPacketsAccumulated; + @JsonProperty("receivedErrorPacketsDelta") + private Double receivedErrorPacketsDelta; + @JsonProperty("receivedMulticastPacketsAccumulated") + private Double receivedMulticastPacketsAccumulated; + @JsonProperty("receivedMulticastPacketsDelta") + private Double receivedMulticastPacketsDelta; + @JsonProperty("receivedOctetsAccumulated") + private Double receivedOctetsAccumulated; + @JsonProperty("receivedOctetsDelta") + private Double receivedOctetsDelta; + @JsonProperty("receivedTotalPacketsAccumulated") + private Double receivedTotalPacketsAccumulated; + @JsonProperty("receivedTotalPacketsDelta") + private Double receivedTotalPacketsDelta; + @JsonProperty("receivedUnicastPacketsAccumulated") + private Double receivedUnicastPacketsAccumulated; + @JsonProperty("receivedUnicastPacketsDelta") + private Double receivedUnicastPacketsDelta; + @JsonProperty("transmittedBroadcastPacketsAccumulated") + private Double transmittedBroadcastPacketsAccumulated; + @JsonProperty("transmittedBroadcastPacketsDelta") + private Double transmittedBroadcastPacketsDelta; + @JsonProperty("transmittedDiscardedPacketsAccumulated") + private Double transmittedDiscardedPacketsAccumulated; + @JsonProperty("transmittedDiscardedPacketsDelta") + private Double transmittedDiscardedPacketsDelta; + @JsonProperty("transmittedErrorPacketsAccumulated") + private Double transmittedErrorPacketsAccumulated; + @JsonProperty("transmittedErrorPacketsDelta") + private Double transmittedErrorPacketsDelta; + @JsonProperty("transmittedMulticastPacketsAccumulated") + private Double transmittedMulticastPacketsAccumulated; + @JsonProperty("transmittedMulticastPacketsDelta") + private Double transmittedMulticastPacketsDelta; + @JsonProperty("transmittedOctetsAccumulated") + private Double transmittedOctetsAccumulated; + @JsonProperty("transmittedOctetsDelta") + private Double transmittedOctetsDelta; + @JsonProperty("transmittedTotalPacketsAccumulated") + private Double transmittedTotalPacketsAccumulated; + @JsonProperty("transmittedTotalPacketsDelta") + private Double transmittedTotalPacketsDelta; + @JsonProperty("transmittedUnicastPacketsAccumulated") + private Double transmittedUnicastPacketsAccumulated; + @JsonProperty("transmittedUnicastPacketsDelta") + private Double transmittedUnicastPacketsDelta; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("valuesAreSuspect") + public String getValuesAreSuspect() { + return valuesAreSuspect; + } + + @JsonProperty("valuesAreSuspect") + public void setValuesAreSuspect(String valuesAreSuspect) { + this.valuesAreSuspect = valuesAreSuspect; + } + + @JsonProperty("vNicIdentifier") + public String getVNicIdentifier() { + return vNicIdentifier; + } + + @JsonProperty("vNicIdentifier") + public void setVNicIdentifier(String vNicIdentifier) { + this.vNicIdentifier = vNicIdentifier; + } + + @JsonProperty("receivedBroadcastPacketsAccumulated") + public Double getReceivedBroadcastPacketsAccumulated() { + return receivedBroadcastPacketsAccumulated; + } + + @JsonProperty("receivedBroadcastPacketsAccumulated") + public void setReceivedBroadcastPacketsAccumulated(Double receivedBroadcastPacketsAccumulated) { + this.receivedBroadcastPacketsAccumulated = receivedBroadcastPacketsAccumulated; + } + + @JsonProperty("receivedBroadcastPacketsDelta") + public Double getReceivedBroadcastPacketsDelta() { + return receivedBroadcastPacketsDelta; + } + + @JsonProperty("receivedBroadcastPacketsDelta") + public void setReceivedBroadcastPacketsDelta(Double receivedBroadcastPacketsDelta) { + this.receivedBroadcastPacketsDelta = receivedBroadcastPacketsDelta; + } + + @JsonProperty("receivedDiscardedPacketsAccumulated") + public Double getReceivedDiscardedPacketsAccumulated() { + return receivedDiscardedPacketsAccumulated; + } + + @JsonProperty("receivedDiscardedPacketsAccumulated") + public void setReceivedDiscardedPacketsAccumulated(Double receivedDiscardedPacketsAccumulated) { + this.receivedDiscardedPacketsAccumulated = receivedDiscardedPacketsAccumulated; + } + + @JsonProperty("receivedDiscardedPacketsDelta") + public Double getReceivedDiscardedPacketsDelta() { + return receivedDiscardedPacketsDelta; + } + + @JsonProperty("receivedDiscardedPacketsDelta") + public void setReceivedDiscardedPacketsDelta(Double receivedDiscardedPacketsDelta) { + this.receivedDiscardedPacketsDelta = receivedDiscardedPacketsDelta; + } + + @JsonProperty("receivedErrorPacketsAccumulated") + public Double getReceivedErrorPacketsAccumulated() { + return receivedErrorPacketsAccumulated; + } + + @JsonProperty("receivedErrorPacketsAccumulated") + public void setReceivedErrorPacketsAccumulated(Double receivedErrorPacketsAccumulated) { + this.receivedErrorPacketsAccumulated = receivedErrorPacketsAccumulated; + } + + @JsonProperty("receivedErrorPacketsDelta") + public Double getReceivedErrorPacketsDelta() { + return receivedErrorPacketsDelta; + } + + @JsonProperty("receivedErrorPacketsDelta") + public void setReceivedErrorPacketsDelta(Double receivedErrorPacketsDelta) { + this.receivedErrorPacketsDelta = receivedErrorPacketsDelta; + } + + @JsonProperty("receivedMulticastPacketsAccumulated") + public Double getReceivedMulticastPacketsAccumulated() { + return receivedMulticastPacketsAccumulated; + } + + @JsonProperty("receivedMulticastPacketsAccumulated") + public void setReceivedMulticastPacketsAccumulated(Double receivedMulticastPacketsAccumulated) { + this.receivedMulticastPacketsAccumulated = receivedMulticastPacketsAccumulated; + } + + @JsonProperty("receivedMulticastPacketsDelta") + public Double getReceivedMulticastPacketsDelta() { + return receivedMulticastPacketsDelta; + } + + @JsonProperty("receivedMulticastPacketsDelta") + public void setReceivedMulticastPacketsDelta(Double receivedMulticastPacketsDelta) { + this.receivedMulticastPacketsDelta = receivedMulticastPacketsDelta; + } + + @JsonProperty("receivedOctetsAccumulated") + public Double getReceivedOctetsAccumulated() { + return receivedOctetsAccumulated; + } + + @JsonProperty("receivedOctetsAccumulated") + public void setReceivedOctetsAccumulated(Double receivedOctetsAccumulated) { + this.receivedOctetsAccumulated = receivedOctetsAccumulated; + } + + @JsonProperty("receivedOctetsDelta") + public Double getReceivedOctetsDelta() { + return receivedOctetsDelta; + } + + @JsonProperty("receivedOctetsDelta") + public void setReceivedOctetsDelta(Double receivedOctetsDelta) { + this.receivedOctetsDelta = receivedOctetsDelta; + } + + @JsonProperty("receivedTotalPacketsAccumulated") + public Double getReceivedTotalPacketsAccumulated() { + return receivedTotalPacketsAccumulated; + } + + @JsonProperty("receivedTotalPacketsAccumulated") + public void setReceivedTotalPacketsAccumulated(Double receivedTotalPacketsAccumulated) { + this.receivedTotalPacketsAccumulated = receivedTotalPacketsAccumulated; + } + + @JsonProperty("receivedTotalPacketsDelta") + public Double getReceivedTotalPacketsDelta() { + return receivedTotalPacketsDelta; + } + + @JsonProperty("receivedTotalPacketsDelta") + public void setReceivedTotalPacketsDelta(Double receivedTotalPacketsDelta) { + this.receivedTotalPacketsDelta = receivedTotalPacketsDelta; + } + + @JsonProperty("receivedUnicastPacketsAccumulated") + public Double getReceivedUnicastPacketsAccumulated() { + return receivedUnicastPacketsAccumulated; + } + + @JsonProperty("receivedUnicastPacketsAccumulated") + public void setReceivedUnicastPacketsAccumulated(Double receivedUnicastPacketsAccumulated) { + this.receivedUnicastPacketsAccumulated = receivedUnicastPacketsAccumulated; + } + + @JsonProperty("receivedUnicastPacketsDelta") + public Double getReceivedUnicastPacketsDelta() { + return receivedUnicastPacketsDelta; + } + + @JsonProperty("receivedUnicastPacketsDelta") + public void setReceivedUnicastPacketsDelta(Double receivedUnicastPacketsDelta) { + this.receivedUnicastPacketsDelta = receivedUnicastPacketsDelta; + } + + @JsonProperty("transmittedBroadcastPacketsAccumulated") + public Double getTransmittedBroadcastPacketsAccumulated() { + return transmittedBroadcastPacketsAccumulated; + } + + @JsonProperty("transmittedBroadcastPacketsAccumulated") + public void setTransmittedBroadcastPacketsAccumulated(Double transmittedBroadcastPacketsAccumulated) { + this.transmittedBroadcastPacketsAccumulated = transmittedBroadcastPacketsAccumulated; + } + + @JsonProperty("transmittedBroadcastPacketsDelta") + public Double getTransmittedBroadcastPacketsDelta() { + return transmittedBroadcastPacketsDelta; + } + + @JsonProperty("transmittedBroadcastPacketsDelta") + public void setTransmittedBroadcastPacketsDelta(Double transmittedBroadcastPacketsDelta) { + this.transmittedBroadcastPacketsDelta = transmittedBroadcastPacketsDelta; + } + + @JsonProperty("transmittedDiscardedPacketsAccumulated") + public Double getTransmittedDiscardedPacketsAccumulated() { + return transmittedDiscardedPacketsAccumulated; + } + + @JsonProperty("transmittedDiscardedPacketsAccumulated") + public void setTransmittedDiscardedPacketsAccumulated(Double transmittedDiscardedPacketsAccumulated) { + this.transmittedDiscardedPacketsAccumulated = transmittedDiscardedPacketsAccumulated; + } + + @JsonProperty("transmittedDiscardedPacketsDelta") + public Double getTransmittedDiscardedPacketsDelta() { + return transmittedDiscardedPacketsDelta; + } + + @JsonProperty("transmittedDiscardedPacketsDelta") + public void setTransmittedDiscardedPacketsDelta(Double transmittedDiscardedPacketsDelta) { + this.transmittedDiscardedPacketsDelta = transmittedDiscardedPacketsDelta; + } + + @JsonProperty("transmittedErrorPacketsAccumulated") + public Double getTransmittedErrorPacketsAccumulated() { + return transmittedErrorPacketsAccumulated; + } + + @JsonProperty("transmittedErrorPacketsAccumulated") + public void setTransmittedErrorPacketsAccumulated(Double transmittedErrorPacketsAccumulated) { + this.transmittedErrorPacketsAccumulated = transmittedErrorPacketsAccumulated; + } + + @JsonProperty("transmittedErrorPacketsDelta") + public Double getTransmittedErrorPacketsDelta() { + return transmittedErrorPacketsDelta; + } + + @JsonProperty("transmittedErrorPacketsDelta") + public void setTransmittedErrorPacketsDelta(Double transmittedErrorPacketsDelta) { + this.transmittedErrorPacketsDelta = transmittedErrorPacketsDelta; + } + + @JsonProperty("transmittedMulticastPacketsAccumulated") + public Double getTransmittedMulticastPacketsAccumulated() { + return transmittedMulticastPacketsAccumulated; + } + + @JsonProperty("transmittedMulticastPacketsAccumulated") + public void setTransmittedMulticastPacketsAccumulated(Double transmittedMulticastPacketsAccumulated) { + this.transmittedMulticastPacketsAccumulated = transmittedMulticastPacketsAccumulated; + } + + @JsonProperty("transmittedMulticastPacketsDelta") + public Double getTransmittedMulticastPacketsDelta() { + return transmittedMulticastPacketsDelta; + } + + @JsonProperty("transmittedMulticastPacketsDelta") + public void setTransmittedMulticastPacketsDelta(Double transmittedMulticastPacketsDelta) { + this.transmittedMulticastPacketsDelta = transmittedMulticastPacketsDelta; + } + + @JsonProperty("transmittedOctetsAccumulated") + public Double getTransmittedOctetsAccumulated() { + return transmittedOctetsAccumulated; + } + + @JsonProperty("transmittedOctetsAccumulated") + public void setTransmittedOctetsAccumulated(Double transmittedOctetsAccumulated) { + this.transmittedOctetsAccumulated = transmittedOctetsAccumulated; + } + + @JsonProperty("transmittedOctetsDelta") + public Double getTransmittedOctetsDelta() { + return transmittedOctetsDelta; + } + + @JsonProperty("transmittedOctetsDelta") + public void setTransmittedOctetsDelta(Double transmittedOctetsDelta) { + this.transmittedOctetsDelta = transmittedOctetsDelta; + } + + @JsonProperty("transmittedTotalPacketsAccumulated") + public Double getTransmittedTotalPacketsAccumulated() { + return transmittedTotalPacketsAccumulated; + } + + @JsonProperty("transmittedTotalPacketsAccumulated") + public void setTransmittedTotalPacketsAccumulated(Double transmittedTotalPacketsAccumulated) { + this.transmittedTotalPacketsAccumulated = transmittedTotalPacketsAccumulated; + } + + @JsonProperty("transmittedTotalPacketsDelta") + public Double getTransmittedTotalPacketsDelta() { + return transmittedTotalPacketsDelta; + } + + @JsonProperty("transmittedTotalPacketsDelta") + public void setTransmittedTotalPacketsDelta(Double transmittedTotalPacketsDelta) { + this.transmittedTotalPacketsDelta = transmittedTotalPacketsDelta; + } + + @JsonProperty("transmittedUnicastPacketsAccumulated") + public Double getTransmittedUnicastPacketsAccumulated() { + return transmittedUnicastPacketsAccumulated; + } + + @JsonProperty("transmittedUnicastPacketsAccumulated") + public void setTransmittedUnicastPacketsAccumulated(Double transmittedUnicastPacketsAccumulated) { + this.transmittedUnicastPacketsAccumulated = transmittedUnicastPacketsAccumulated; + } + + @JsonProperty("transmittedUnicastPacketsDelta") + public Double getTransmittedUnicastPacketsDelta() { + return transmittedUnicastPacketsDelta; + } + + @JsonProperty("transmittedUnicastPacketsDelta") + public void setTransmittedUnicastPacketsDelta(Double transmittedUnicastPacketsDelta) { + this.transmittedUnicastPacketsDelta = transmittedUnicastPacketsDelta; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/VendorVnfNameFields.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/VendorVnfNameFields.java new file mode 100644 index 0000000..518e92e --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/VendorVnfNameFields.java @@ -0,0 +1,90 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "vendorName", + "vfModuleName", + "vnfName" +}) +public class VendorVnfNameFields { + + @JsonProperty("vendorName") + private String vendorName; + @JsonProperty("vfModuleName") + private String vfModuleName; + @JsonProperty("vnfName") + private String vnfName; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("vendorName") + public String getVendorName() { + return vendorName; + } + + @JsonProperty("vendorName") + public void setVendorName(String vendorName) { + this.vendorName = vendorName; + } + + @JsonProperty("vfModuleName") + public String getVfModuleName() { + return vfModuleName; + } + + @JsonProperty("vfModuleName") + public void setVfModuleName(String vfModuleName) { + this.vfModuleName = vfModuleName; + } + + @JsonProperty("vnfName") + public String getVnfName() { + return vnfName; + } + + @JsonProperty("vnfName") + public void setVnfName(String vnfName) { + this.vnfName = vnfName; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/VoiceQualityFields.java b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/VoiceQualityFields.java new file mode 100644 index 0000000..2b3651d --- /dev/null +++ b/UniversalVesAdapter/src/main/java/org/onap/dcaegen2/ves/domain/VoiceQualityFields.java @@ -0,0 +1,169 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyOrder; + +@JsonInclude(JsonInclude.Include.NON_NULL) +@JsonPropertyOrder({ + "calleeSideCodec", + "callerSideCodec", + "correlator", + "midCallRtcp", + "vendorVnfNameFields", + "voiceQualityFieldsVersion", + "additionalInformation", + "endOfCallVqmSummaries", + "phoneNumber" +}) +public class VoiceQualityFields { + + @JsonProperty("calleeSideCodec") + private String calleeSideCodec; + @JsonProperty("callerSideCodec") + private String callerSideCodec; + @JsonProperty("correlator") + private String correlator; + @JsonProperty("midCallRtcp") + private String midCallRtcp; + @JsonProperty("vendorVnfNameFields") + private VendorVnfNameFields vendorVnfNameFields; + @JsonProperty("voiceQualityFieldsVersion") + private Double voiceQualityFieldsVersion; + @JsonProperty("additionalInformation") + private List<AdditionalInformation> additionalInformation = null; + @JsonProperty("endOfCallVqmSummaries") + private EndOfCallVqmSummaries endOfCallVqmSummaries; + @JsonProperty("phoneNumber") + private String phoneNumber; + @JsonIgnore + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @JsonProperty("calleeSideCodec") + public String getCalleeSideCodec() { + return calleeSideCodec; + } + + @JsonProperty("calleeSideCodec") + public void setCalleeSideCodec(String calleeSideCodec) { + this.calleeSideCodec = calleeSideCodec; + } + + @JsonProperty("callerSideCodec") + public String getCallerSideCodec() { + return callerSideCodec; + } + + @JsonProperty("callerSideCodec") + public void setCallerSideCodec(String callerSideCodec) { + this.callerSideCodec = callerSideCodec; + } + + @JsonProperty("correlator") + public String getCorrelator() { + return correlator; + } + + @JsonProperty("correlator") + public void setCorrelator(String correlator) { + this.correlator = correlator; + } + + @JsonProperty("midCallRtcp") + public String getMidCallRtcp() { + return midCallRtcp; + } + + @JsonProperty("midCallRtcp") + public void setMidCallRtcp(String midCallRtcp) { + this.midCallRtcp = midCallRtcp; + } + + @JsonProperty("vendorVnfNameFields") + public VendorVnfNameFields getVendorVnfNameFields() { + return vendorVnfNameFields; + } + + @JsonProperty("vendorVnfNameFields") + public void setVendorVnfNameFields(VendorVnfNameFields vendorVnfNameFields) { + this.vendorVnfNameFields = vendorVnfNameFields; + } + + @JsonProperty("voiceQualityFieldsVersion") + public Double getVoiceQualityFieldsVersion() { + return voiceQualityFieldsVersion; + } + + @JsonProperty("voiceQualityFieldsVersion") + public void setVoiceQualityFieldsVersion(Double voiceQualityFieldsVersion) { + this.voiceQualityFieldsVersion = voiceQualityFieldsVersion; + } + + @JsonProperty("additionalInformation") + public List<AdditionalInformation> getAdditionalInformation() { + return additionalInformation; + } + + @JsonProperty("additionalInformation") + public void setAdditionalInformation(List<AdditionalInformation> additionalInformation) { + this.additionalInformation = additionalInformation; + } + + @JsonProperty("endOfCallVqmSummaries") + public EndOfCallVqmSummaries getEndOfCallVqmSummaries() { + return endOfCallVqmSummaries; + } + + @JsonProperty("endOfCallVqmSummaries") + public void setEndOfCallVqmSummaries(EndOfCallVqmSummaries endOfCallVqmSummaries) { + this.endOfCallVqmSummaries = endOfCallVqmSummaries; + } + + @JsonProperty("phoneNumber") + public String getPhoneNumber() { + return phoneNumber; + } + + @JsonProperty("phoneNumber") + public void setPhoneNumber(String phoneNumber) { + this.phoneNumber = phoneNumber; + } + + @JsonAnyGetter + public Map<String, Object> getAdditionalProperties() { + return this.additionalProperties; + } + + @JsonAnySetter + public void setAdditionalProperty(String name, Object value) { + this.additionalProperties.put(name, value); + } + + + +} diff --git a/UniversalVesAdapter/src/main/java/org/onap/universalvesadapter/utils/SmooksUtils.java b/UniversalVesAdapter/src/main/java/org/onap/universalvesadapter/utils/SmooksUtils.java index df36da6..8c17dc2 100644 --- a/UniversalVesAdapter/src/main/java/org/onap/universalvesadapter/utils/SmooksUtils.java +++ b/UniversalVesAdapter/src/main/java/org/onap/universalvesadapter/utils/SmooksUtils.java @@ -70,6 +70,7 @@ public class SmooksUtils { Locale.setDefault(defaultLocale); VesEvent vesEvent = (VesEvent) executionContext.getBeanContext().getBean("vesEvent"); LOGGER.debug("Converted vesEvent from incoming json"); + return vesEvent; } diff --git a/UniversalVesAdapter/src/main/resources/application.properties b/UniversalVesAdapter/src/main/resources/application.properties index 55074d4..0aefded 100644 --- a/UniversalVesAdapter/src/main/resources/application.properties +++ b/UniversalVesAdapter/src/main/resources/application.properties @@ -6,6 +6,6 @@ universal.configFiles=snmp:snmpTrapToVes.xml,default:defaultConfig.xml fileService.url=http://localhost:8888/fileAsString/ messagesInBatch=1000 messagesInTimeInterval=5000 -mapperConfig.file=D:/DCAE User Story/Commits/newwww/mapper/UniversalVesAdapter/src/main/resources/MapperConfig.json +mapperConfig.file=MapperConfig.json dmaap.consumer_props=/src/main/resources/dme2/consumer.properties dmaap.publisher_props=/src/main/resources/dme2/publisher.properties
\ No newline at end of file diff --git a/UniversalVesAdapter/src/main/resources/snmptovesTest.xml b/UniversalVesAdapter/src/main/resources/snmptovesTest.xml new file mode 100644 index 0000000..5fad2c9 --- /dev/null +++ b/UniversalVesAdapter/src/main/resources/snmptovesTest.xml @@ -0,0 +1,54 @@ +<?xml version="1.0" encoding="UTF-8"?> +<smooks-resource-list + xmlns="http://www.milyn.org/xsd/smooks-1.1.xsd" + xmlns:json="http://www.milyn.org/xsd/smooks/json-1.1.xsd" + xmlns:jb="http://www.milyn.org/xsd/smooks/javabean-1.2.xsd"> + <json:reader rootName="simple" keyWhitspaceReplacement="-"> + </json:reader> + <!-- <jb:bean class="com.example.demo.Simple" beanId="simple" createOnElement="simple"> + <jb:value property="orderId" data="#/orderId" /> + <jb:value property="username" data="#/username" /> + <jb:wiring property="customer" beanIdRef="customer"/> + <jb:wiring property="orderItems" beanIdRef="orderItems"/> + </jb:bean> --> + + <jb:bean class="org.onap.dcaegen2.ves.domain.VesEvent" beanId="vesEvent" createOnElement="simple"> + <jb:wiring property="event" beanIdRef="event"/> + </jb:bean> + + <jb:bean class="org.onap.dcaegen2.ves.domain.Event" beanId="event" createOnElement="simple"> + <jb:wiring property="commonEventHeader" beanIdRef="commonEventHeader"/> + <jb:wiring property="faultFields" beanIdRef="faultFields"/> + <!--<jb:wiring property="measurementsForVfScalingFields" beanIdRef="measurementsForVfScalingFields"/> --> + </jb:bean> + <!--<jb:bean class="org.onap.dcaegen2.ves.domain.MeasurementsForVfScalingFields" beanId="measurementsForVfScalingFields" createOnElement="simple"> + <jb:wiring property="additionalMeasurements" beanIdRef="additionalMeasurements"/> + </jb:bean>--> + + <jb:bean class="org.onap.dcaegen2.ves.domain.CommonEventHeader" beanId="commonEventHeader" createOnElement="simple"> + <jb:value property="eventId" data="#/community" /> + <jb:value property="eventName" data="#/protocol-version" /> + <jb:value property="domain" data="#/trap-category" /> + <jb:value property="sequence" data="#/time-received" decoder="Long"/> + <jb:value property="lastEpochMicrosec" data="#/community-len" decoder="Double" /> + <jb:value property="startEpochMicrosec" data="#/notify-OID-len" /> + </jb:bean> + + <jb:bean class="org.onap.dcaegen2.ves.domain.FaultFields" beanId="faultFields" createOnElement="simple"> + <jb:value property="alarmCondition" data="#/cambria.partition" /> + <jb:value property="eventSeverity" data="#/notify-OID" /> + <jb:value property="eventSourceType" data="#/agent-name" /> + <jb:value property="specificProblem" data="#/agent-address" /> + <jb:value property="faultFieldsVersion" data="#/epoch_serno" decoder="Double" /> + </jb:bean> + + + <!--<jb:bean class="java.util.ArrayList" beanId="additionalMeasurements" createOnElement="simple"> + <jb:wiring beanIdRef="additionalMeasurement"/> + </jb:bean> + + <jb:bean class="org.onap.dcaegen2.ves.domain.AdditionalMeasurement" beanId="additionalMeasurement" createOnElement="varbinds/element"> + <jb:value property="name" data="#/varbind_value" /> + </jb:bean> --> + +</smooks-resource-list>
\ No newline at end of file diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/AdditionalFieldTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/AdditionalFieldTest.java index c7ba7e0..ce4c8c7 100644 --- a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/AdditionalFieldTest.java +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/AdditionalFieldTest.java @@ -31,21 +31,40 @@ public class AdditionalFieldTest { @Autowired AdditionalField additionalField = new AdditionalField(); - Object value1 = new Object(); - Map<String, Object> map = new HashMap<String, Object>(); - +// Object value1 = new Object(); +// Map<String, Object> map = new HashMap<String, Object>(); +// +// @Test +// public void test() { +// additionalField.setAdditionalProperty("name", value1); +// additionalField.setName("name2"); +// additionalField.setValue("value2"); +// +// map.put("name", value1); +// assertEquals(additionalField.getName(),"name2"); +// assertEquals(additionalField.getValue(),"value2"); +// assertEquals(additionalField.getAdditionalProperties(),map); +// assert (additionalField.toString() != null); +// assert (additionalField.hashCode() != 0); +// } + + @Test + public void testgetName() { + additionalField.getName(); + } + @Test - public void test() { - additionalField.setAdditionalProperty("name", value1); - additionalField.setName("name2"); - additionalField.setValue("value2"); - - map.put("name", value1); - assertEquals(additionalField.getName(),"name2"); - assertEquals(additionalField.getValue(),"value2"); - assertEquals(additionalField.getAdditionalProperties(),map); - assert (additionalField.toString() != null); - assert (additionalField.hashCode() != 0); + public void testsetName() { + additionalField.setName("Test"); } + @Test + public void testgetValue() { + additionalField.getValue(); + } + + @Test + public void testsetValue() { + additionalField.setValue("Test"); + } } diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/AdditionalInformationTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/AdditionalInformationTest.java new file mode 100644 index 0000000..058cb79 --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/AdditionalInformationTest.java @@ -0,0 +1,53 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import static org.junit.Assert.*; + +import java.util.HashMap; +import java.util.Map; + +import org.junit.Test; +import org.springframework.beans.factory.annotation.Autowired; + +public class AdditionalInformationTest { + @Autowired + AdditionalInformation ai = new AdditionalInformation(); + Object value; + Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + + @Test + public void testAdditionalInformation() { + + ai.setName("name"); + ai.setValue("value"); + ai.setAdditionalProperty("name", value); + assertEquals(ai.getName(), "name"); + assertEquals(ai.getValue(), "value"); + additionalProperties.put("name", value); + assertEquals(additionalProperties, ai.getAdditionalProperties()); + assert (ai.toString() != null); + assert (ai.hashCode() != 0); + assertEquals(true, ai.equals(ai)); + + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/AdditionalParameterTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/AdditionalParameterTest.java new file mode 100644 index 0000000..92cda09 --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/AdditionalParameterTest.java @@ -0,0 +1,163 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.Map; + +import org.junit.Test; + +public class AdditionalParameterTest { + + private AdditionalParameter createTestSubject() { + return new AdditionalParameter(); + } + + @Test + public void testGetCriticality() throws Exception { + AdditionalParameter testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getCriticality(); + } + + @Test + public void testSetCriticality() throws Exception { + AdditionalParameter testSubject; + String criticality = ""; + + // default test + testSubject = createTestSubject(); + testSubject.setCriticality(criticality); + } + + @Test + public void testGetName() throws Exception { + AdditionalParameter testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getName(); + } + + @Test + public void testSetName() throws Exception { + AdditionalParameter testSubject; + String name = ""; + + // default test + testSubject = createTestSubject(); + testSubject.setName(name); + } + + @Test + public void testGetThresholdCrossed() throws Exception { + AdditionalParameter testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getThresholdCrossed(); + } + + @Test + public void testSetThresholdCrossed() throws Exception { + AdditionalParameter testSubject; + String thresholdCrossed = ""; + + // default test + testSubject = createTestSubject(); + testSubject.setThresholdCrossed(thresholdCrossed); + } + + @Test + public void testGetValue() throws Exception { + AdditionalParameter testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getValue(); + } + + @Test + public void testSetValue() throws Exception { + AdditionalParameter testSubject; + String value = ""; + + // default test + testSubject = createTestSubject(); + testSubject.setValue(value); + } + + @Test + public void testGetAdditionalProperties() throws Exception { + AdditionalParameter testSubject; + Map<String, Object> result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getAdditionalProperties(); + } + + @Test + public void testSetAdditionalProperty() throws Exception { + AdditionalParameter testSubject; + String name = ""; + Object value = null; + + // default test + testSubject = createTestSubject(); + testSubject.setAdditionalProperty(name, value); + } + + @Test + public void testToString() throws Exception { + AdditionalParameter testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.toString(); + } + + @Test + public void testHashCode() throws Exception { + AdditionalParameter testSubject; + int result; + + // default test + testSubject = createTestSubject(); + result = testSubject.hashCode(); + } + + @Test + public void testEquals() throws Exception { + AdditionalParameter testSubject; + Object other = null; + boolean result; + + // default test + testSubject = createTestSubject(); + result = testSubject.equals(other); + } +}
\ No newline at end of file diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/CodecUsageArrayTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/CodecUsageArrayTest.java new file mode 100644 index 0000000..dc79f44 --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/CodecUsageArrayTest.java @@ -0,0 +1,56 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import static org.junit.Assert.*; + +import java.util.HashMap; +import java.util.Map; + +import org.junit.Test; +import org.springframework.beans.factory.annotation.Autowired; + +public class CodecUsageArrayTest { + + @Autowired + CodecUsageArray codecUsageArray = new CodecUsageArray(); + Object value; + Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @Test + public void test() { + codecUsageArray.setAdditionalProperty("name", value); + codecUsageArray.setCodecIdentifier("test"); + codecUsageArray.setNumberInUse(1L); + additionalProperties.put("name", value); + + + assertEquals(additionalProperties, codecUsageArray.getAdditionalProperties()); + assertEquals("test", codecUsageArray.getCodecIdentifier()); + assertEquals(new Long(1L), codecUsageArray.getNumberInUse()); + assert (codecUsageArray.toString() != null); + assert (codecUsageArray.hashCode() != 0); + assertEquals(true, codecUsageArray.equals(codecUsageArray)); + + + + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/CpuUsageArrayTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/CpuUsageArrayTest.java new file mode 100644 index 0000000..c7d3e3b --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/CpuUsageArrayTest.java @@ -0,0 +1,69 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import static org.junit.Assert.*; + +import java.util.HashMap; +import java.util.Map; + +import org.junit.Test; +import org.springframework.beans.factory.annotation.Autowired; + +public class CpuUsageArrayTest { + + @Autowired + CpuUsageArray cpuUsageArray = new CpuUsageArray(); + Object value; + Map<String, Object> additionalProperties = new HashMap<String, Object>(); + @Test + public void test() { + + cpuUsageArray.setAdditionalProperty("name", value); + cpuUsageArray.setCpuIdentifier("test"); + cpuUsageArray.setCpuIdle(2.2); + cpuUsageArray.setCpuUsageInterrupt(2.2); + cpuUsageArray.setCpuUsageNice(2.2); + cpuUsageArray.setCpuUsageSoftIrq(2.2); + cpuUsageArray.setCpuUsageSteal(2.2); + cpuUsageArray.setCpuUsageSystem(2.2); + cpuUsageArray.setCpuUsageUser(2.2); + cpuUsageArray.setCpuWait(2.2); + cpuUsageArray.setPercentUsage(2.2); + additionalProperties.put("name", value); + + assertEquals(additionalProperties, cpuUsageArray.getAdditionalProperties()); + assertEquals(new Double(2.2), cpuUsageArray.getCpuIdle()); + assertEquals("test", cpuUsageArray.getCpuIdentifier()); + assertEquals(new Double(2.2), cpuUsageArray.getCpuUsageInterrupt()); + assertEquals(new Double(2.2), cpuUsageArray.getCpuUsageNice()); + assertEquals(new Double(2.2), cpuUsageArray.getCpuUsageSoftIrq()); + assertEquals(new Double(2.2), cpuUsageArray.getCpuUsageSteal()); + assertEquals(new Double(2.2), cpuUsageArray.getCpuUsageSystem()); + assertEquals(new Double(2.2), cpuUsageArray.getCpuUsageUser()); + assertEquals(new Double(2.2), cpuUsageArray.getCpuWait()); + assertEquals(new Double(2.2), cpuUsageArray.getPercentUsage()); + assert (cpuUsageArray.toString() != null); + assert (cpuUsageArray.hashCode() != 0); + assertEquals(true, cpuUsageArray.equals(cpuUsageArray)); + + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/EndOfCallVqmSummariesTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/EndOfCallVqmSummariesTest.java new file mode 100644 index 0000000..56aacc1 --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/EndOfCallVqmSummariesTest.java @@ -0,0 +1,503 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.Map; + +import org.junit.Test; + +public class EndOfCallVqmSummariesTest { + + private EndOfCallVqmSummaries createTestSubject() { + return new EndOfCallVqmSummaries(); + } + + @Test + public void testGetAdjacencyName() throws Exception { + EndOfCallVqmSummaries testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getAdjacencyName(); + } + + @Test + public void testSetAdjacencyName() throws Exception { + EndOfCallVqmSummaries testSubject; + String adjacencyName = ""; + + // default test + testSubject = createTestSubject(); + testSubject.setAdjacencyName(adjacencyName); + } + + @Test + public void testGetEndpointDescription() throws Exception { + EndOfCallVqmSummaries testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getEndpointDescription(); + } + + @Test + public void testSetEndpointDescription() throws Exception { + EndOfCallVqmSummaries testSubject; + String endpointDescription = ""; + + // default test + testSubject = createTestSubject(); + testSubject.setEndpointDescription(endpointDescription); + } + + @Test + public void testGetEndpointJitter() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getEndpointJitter(); + } + + @Test + public void testSetEndpointJitter() throws Exception { + EndOfCallVqmSummaries testSubject; + Double endpointJitter = null; + + // default test + testSubject = createTestSubject(); + testSubject.setEndpointJitter(endpointJitter); + } + + @Test + public void testGetEndpointRtpOctetsDiscarded() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getEndpointRtpOctetsDiscarded(); + } + + @Test + public void testSetEndpointRtpOctetsDiscarded() throws Exception { + EndOfCallVqmSummaries testSubject; + Double endpointRtpOctetsDiscarded = null; + + // default test + testSubject = createTestSubject(); + testSubject.setEndpointRtpOctetsDiscarded(endpointRtpOctetsDiscarded); + } + + @Test + public void testGetEndpointRtpOctetsReceived() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getEndpointRtpOctetsReceived(); + } + + @Test + public void testSetEndpointRtpOctetsReceived() throws Exception { + EndOfCallVqmSummaries testSubject; + Double endpointRtpOctetsReceived = null; + + // default test + testSubject = createTestSubject(); + testSubject.setEndpointRtpOctetsReceived(endpointRtpOctetsReceived); + } + + @Test + public void testGetEndpointRtpOctetsSent() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getEndpointRtpOctetsSent(); + } + + @Test + public void testSetEndpointRtpOctetsSent() throws Exception { + EndOfCallVqmSummaries testSubject; + Double endpointRtpOctetsSent = null; + + // default test + testSubject = createTestSubject(); + testSubject.setEndpointRtpOctetsSent(endpointRtpOctetsSent); + } + + @Test + public void testGetEndpointRtpPacketsDiscarded() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getEndpointRtpPacketsDiscarded(); + } + + @Test + public void testSetEndpointRtpPacketsDiscarded() throws Exception { + EndOfCallVqmSummaries testSubject; + Double endpointRtpPacketsDiscarded = null; + + // default test + testSubject = createTestSubject(); + testSubject.setEndpointRtpPacketsDiscarded(endpointRtpPacketsDiscarded); + } + + @Test + public void testGetEndpointRtpPacketsReceived() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getEndpointRtpPacketsReceived(); + } + + @Test + public void testSetEndpointRtpPacketsReceived() throws Exception { + EndOfCallVqmSummaries testSubject; + Double endpointRtpPacketsReceived = null; + + // default test + testSubject = createTestSubject(); + testSubject.setEndpointRtpPacketsReceived(endpointRtpPacketsReceived); + } + + @Test + public void testGetEndpointRtpPacketsSent() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getEndpointRtpPacketsSent(); + } + + @Test + public void testSetEndpointRtpPacketsSent() throws Exception { + EndOfCallVqmSummaries testSubject; + Double endpointRtpPacketsSent = null; + + // default test + testSubject = createTestSubject(); + testSubject.setEndpointRtpPacketsSent(endpointRtpPacketsSent); + } + + @Test + public void testGetLocalJitter() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getLocalJitter(); + } + + @Test + public void testSetLocalJitter() throws Exception { + EndOfCallVqmSummaries testSubject; + Double localJitter = null; + + // default test + testSubject = createTestSubject(); + testSubject.setLocalJitter(localJitter); + } + + @Test + public void testGetLocalRtpOctetsDiscarded() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getLocalRtpOctetsDiscarded(); + } + + @Test + public void testSetLocalRtpOctetsDiscarded() throws Exception { + EndOfCallVqmSummaries testSubject; + Double localRtpOctetsDiscarded = null; + + // default test + testSubject = createTestSubject(); + testSubject.setLocalRtpOctetsDiscarded(localRtpOctetsDiscarded); + } + + @Test + public void testGetLocalRtpOctetsReceived() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getLocalRtpOctetsReceived(); + } + + @Test + public void testSetLocalRtpOctetsReceived() throws Exception { + EndOfCallVqmSummaries testSubject; + Double localRtpOctetsReceived = null; + + // default test + testSubject = createTestSubject(); + testSubject.setLocalRtpOctetsReceived(localRtpOctetsReceived); + } + + @Test + public void testGetLocalRtpOctetsSent() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getLocalRtpOctetsSent(); + } + + @Test + public void testSetLocalRtpOctetsSent() throws Exception { + EndOfCallVqmSummaries testSubject; + Double localRtpOctetsSent = null; + + // default test + testSubject = createTestSubject(); + testSubject.setLocalRtpOctetsSent(localRtpOctetsSent); + } + + @Test + public void testGetLocalRtpPacketsDiscarded() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getLocalRtpPacketsDiscarded(); + } + + @Test + public void testSetLocalRtpPacketsDiscarded() throws Exception { + EndOfCallVqmSummaries testSubject; + Double localRtpPacketsDiscarded = null; + + // default test + testSubject = createTestSubject(); + testSubject.setLocalRtpPacketsDiscarded(localRtpPacketsDiscarded); + } + + @Test + public void testGetLocalRtpPacketsReceived() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getLocalRtpPacketsReceived(); + } + + @Test + public void testSetLocalRtpPacketsReceived() throws Exception { + EndOfCallVqmSummaries testSubject; + Double localRtpPacketsReceived = null; + + // default test + testSubject = createTestSubject(); + testSubject.setLocalRtpPacketsReceived(localRtpPacketsReceived); + } + + @Test + public void testGetLocalRtpPacketsSent() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getLocalRtpPacketsSent(); + } + + @Test + public void testSetLocalRtpPacketsSent() throws Exception { + EndOfCallVqmSummaries testSubject; + Double localRtpPacketsSent = null; + + // default test + testSubject = createTestSubject(); + testSubject.setLocalRtpPacketsSent(localRtpPacketsSent); + } + + @Test + public void testGetMosCqe() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getMosCqe(); + } + + @Test + public void testSetMosCqe() throws Exception { + EndOfCallVqmSummaries testSubject; + Double mosCqe = null; + + // default test + testSubject = createTestSubject(); + testSubject.setMosCqe(mosCqe); + } + + @Test + public void testGetPacketsLost() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getPacketsLost(); + } + + @Test + public void testSetPacketsLost() throws Exception { + EndOfCallVqmSummaries testSubject; + Double packetsLost = null; + + // default test + testSubject = createTestSubject(); + testSubject.setPacketsLost(packetsLost); + } + + @Test + public void testGetPacketLossPercent() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getPacketLossPercent(); + } + + @Test + public void testSetPacketLossPercent() throws Exception { + EndOfCallVqmSummaries testSubject; + Double packetLossPercent = null; + + // default test + testSubject = createTestSubject(); + testSubject.setPacketLossPercent(packetLossPercent); + } + + @Test + public void testGetRFactor() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getRFactor(); + } + + @Test + public void testSetRFactor() throws Exception { + EndOfCallVqmSummaries testSubject; + Double rFactor = null; + + // default test + testSubject = createTestSubject(); + testSubject.setRFactor(rFactor); + } + + @Test + public void testGetRoundTripDelay() throws Exception { + EndOfCallVqmSummaries testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getRoundTripDelay(); + } + + @Test + public void testSetRoundTripDelay() throws Exception { + EndOfCallVqmSummaries testSubject; + Double roundTripDelay = null; + + // default test + testSubject = createTestSubject(); + testSubject.setRoundTripDelay(roundTripDelay); + } + + @Test + public void testGetAdditionalProperties() throws Exception { + EndOfCallVqmSummaries testSubject; + Map<String, Object> result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getAdditionalProperties(); + } + + @Test + public void testSetAdditionalProperty() throws Exception { + EndOfCallVqmSummaries testSubject; + String name = ""; + Object value = null; + + // default test + testSubject = createTestSubject(); + testSubject.setAdditionalProperty(name, value); + } + + @Test + public void testToString() throws Exception { + EndOfCallVqmSummaries testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.toString(); + } + + @Test + public void testHashCode() throws Exception { + EndOfCallVqmSummaries testSubject; + int result; + + // default test + testSubject = createTestSubject(); + result = testSubject.hashCode(); + } + + @Test + public void testEquals() throws Exception { + EndOfCallVqmSummaries testSubject; + Object other = null; + boolean result; + + // default test + testSubject = createTestSubject(); + result = testSubject.equals(other); + } +}
\ No newline at end of file diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/FeatureUsageArrayTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/FeatureUsageArrayTest.java new file mode 100644 index 0000000..5dfc74c --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/FeatureUsageArrayTest.java @@ -0,0 +1,123 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.Map; + +import org.junit.Test; + +public class FeatureUsageArrayTest { + + private FeatureUsageArray createTestSubject() { + return new FeatureUsageArray(); + } + + @Test + public void testGetFeatureIdentifier() throws Exception { + FeatureUsageArray testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getFeatureIdentifier(); + } + + @Test + public void testSetFeatureIdentifier() throws Exception { + FeatureUsageArray testSubject; + String featureIdentifier = ""; + + // default test + testSubject = createTestSubject(); + testSubject.setFeatureIdentifier(featureIdentifier); + } + + @Test + public void testGetFeatureUtilization() throws Exception { + FeatureUsageArray testSubject; + Long result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getFeatureUtilization(); + } + + @Test + public void testSetFeatureUtilization() throws Exception { + FeatureUsageArray testSubject; + Long featureUtilization = null; + + // default test + testSubject = createTestSubject(); + testSubject.setFeatureUtilization(featureUtilization); + } + + @Test + public void testGetAdditionalProperties() throws Exception { + FeatureUsageArray testSubject; + Map<String, Object> result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getAdditionalProperties(); + } + + @Test + public void testSetAdditionalProperty() throws Exception { + FeatureUsageArray testSubject; + String name = ""; + Object value = null; + + // default test + testSubject = createTestSubject(); + testSubject.setAdditionalProperty(name, value); + } + + @Test + public void testToString() throws Exception { + FeatureUsageArray testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.toString(); + } + + @Test + public void testHashCode() throws Exception { + FeatureUsageArray testSubject; + int result; + + // default test + testSubject = createTestSubject(); + result = testSubject.hashCode(); + } + + @Test + public void testEquals() throws Exception { + FeatureUsageArray testSubject; + Object other = null; + boolean result; + + // default test + testSubject = createTestSubject(); + result = testSubject.equals(other); + } +}
\ No newline at end of file diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/FilesystemUsageArrayTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/FilesystemUsageArrayTest.java new file mode 100644 index 0000000..36b8af6 --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/FilesystemUsageArrayTest.java @@ -0,0 +1,223 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import java.util.Map; + +import org.junit.Test; + +public class FilesystemUsageArrayTest { + + private FilesystemUsageArray createTestSubject() { + return new FilesystemUsageArray(); + } + + @Test + public void testGetBlockConfigured() throws Exception { + FilesystemUsageArray testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getBlockConfigured(); + } + + @Test + public void testSetBlockConfigured() throws Exception { + FilesystemUsageArray testSubject; + Double blockConfigured = null; + + // default test + testSubject = createTestSubject(); + testSubject.setBlockConfigured(blockConfigured); + } + + @Test + public void testGetBlockIops() throws Exception { + FilesystemUsageArray testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getBlockIops(); + } + + @Test + public void testSetBlockIops() throws Exception { + FilesystemUsageArray testSubject; + Double blockIops = null; + + // default test + testSubject = createTestSubject(); + testSubject.setBlockIops(blockIops); + } + + @Test + public void testGetBlockUsed() throws Exception { + FilesystemUsageArray testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getBlockUsed(); + } + + @Test + public void testSetBlockUsed() throws Exception { + FilesystemUsageArray testSubject; + Double blockUsed = null; + + // default test + testSubject = createTestSubject(); + testSubject.setBlockUsed(blockUsed); + } + + @Test + public void testGetEphemeralConfigured() throws Exception { + FilesystemUsageArray testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getEphemeralConfigured(); + } + + @Test + public void testSetEphemeralConfigured() throws Exception { + FilesystemUsageArray testSubject; + Double ephemeralConfigured = null; + + // default test + testSubject = createTestSubject(); + testSubject.setEphemeralConfigured(ephemeralConfigured); + } + + @Test + public void testGetEphemeralIops() throws Exception { + FilesystemUsageArray testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getEphemeralIops(); + } + + @Test + public void testSetEphemeralIops() throws Exception { + FilesystemUsageArray testSubject; + Double ephemeralIops = null; + + // default test + testSubject = createTestSubject(); + testSubject.setEphemeralIops(ephemeralIops); + } + + @Test + public void testGetEphemeralUsed() throws Exception { + FilesystemUsageArray testSubject; + Double result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getEphemeralUsed(); + } + + @Test + public void testSetEphemeralUsed() throws Exception { + FilesystemUsageArray testSubject; + Double ephemeralUsed = null; + + // default test + testSubject = createTestSubject(); + testSubject.setEphemeralUsed(ephemeralUsed); + } + + @Test + public void testGetFilesystemName() throws Exception { + FilesystemUsageArray testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getFilesystemName(); + } + + @Test + public void testSetFilesystemName() throws Exception { + FilesystemUsageArray testSubject; + String filesystemName = ""; + + // default test + testSubject = createTestSubject(); + testSubject.setFilesystemName(filesystemName); + } + + @Test + public void testGetAdditionalProperties() throws Exception { + FilesystemUsageArray testSubject; + Map<String, Object> result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getAdditionalProperties(); + } + + @Test + public void testSetAdditionalProperty() throws Exception { + FilesystemUsageArray testSubject; + String name = ""; + Object value = null; + + // default test + testSubject = createTestSubject(); + testSubject.setAdditionalProperty(name, value); + } + + @Test + public void testToString() throws Exception { + FilesystemUsageArray testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.toString(); + } + + @Test + public void testHashCode() throws Exception { + FilesystemUsageArray testSubject; + int result; + + // default test + testSubject = createTestSubject(); + result = testSubject.hashCode(); + } + + @Test + public void testEquals() throws Exception { + FilesystemUsageArray testSubject; + Object other = null; + boolean result; + + // default test + testSubject = createTestSubject(); + result = testSubject.equals(other); + } +}
\ No newline at end of file diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/HashOfNameValuePairArrayTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/HashOfNameValuePairArrayTest.java new file mode 100644 index 0000000..7be5384 --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/HashOfNameValuePairArrayTest.java @@ -0,0 +1,57 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import static org.junit.Assert.*; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import org.onap.dcaegen2.ves.domain.HashOfNameValuePairArray; +import org.junit.Test; +import org.mockito.Mock; +import org.springframework.beans.factory.annotation.Autowired; + +public class HashOfNameValuePairArrayTest { + + @Autowired + HashOfNameValuePairArray hashOfNameValuePairArray = new HashOfNameValuePairArray(); + Map<String, Object> additionalProperties = new HashMap<String, Object>(); + Object value; + @Mock + List<ArrayOfField_> arrayOfFields; + @Test + public void test() { + hashOfNameValuePairArray.setAdditionalProperty("name", value); + hashOfNameValuePairArray.setArrayOfFields(arrayOfFields); + hashOfNameValuePairArray.setName("name"); + additionalProperties.put("name", value); + + assertEquals(additionalProperties, hashOfNameValuePairArray.getAdditionalProperties()); + assertEquals(arrayOfFields, hashOfNameValuePairArray.getArrayOfFields()); + assertEquals("name", hashOfNameValuePairArray.getName()); + assert (hashOfNameValuePairArray.toString() != null); + assert (hashOfNameValuePairArray.hashCode() != 0); + assertEquals(true, hashOfNameValuePairArray.equals(hashOfNameValuePairArray)); + + + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/ObjectInstanceTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/ObjectInstanceTest.java new file mode 100644 index 0000000..96bb0ac --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/ObjectInstanceTest.java @@ -0,0 +1,57 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import static org.junit.Assert.*; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import org.junit.Test; + +public class ObjectInstanceTest { + + ObjectInstance object = new ObjectInstance(); + ObjectInstance_ objectInstance = new ObjectInstance_(); + Double objectInstanceEpochMicrosec; + List<ObjectKey> objectKeys; + Object value; + Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @Test + public void test() { + object.setObjectInstance(objectInstance); + object.setObjectInstanceEpochMicrosec(objectInstanceEpochMicrosec); + object.setObjectKeys(objectKeys); + object.setAdditionalProperty("name", value); + additionalProperties.put("name", value); + assertEquals(additionalProperties, object.getAdditionalProperties()); + assertEquals(object.getObjectInstance(), objectInstance); + assertEquals(object.getObjectKeys(), objectKeys); + assertEquals(object.getObjectInstanceEpochMicrosec(), objectInstanceEpochMicrosec); + assert(object.toString()!=null); + assert(object.hashCode()!=0); + assertEquals(true, object.equals(object)); + + + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/ObjectInstance_Test.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/ObjectInstance_Test.java new file mode 100644 index 0000000..7080498 --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/ObjectInstance_Test.java @@ -0,0 +1,45 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import static org.junit.Assert.*; + +import java.util.HashMap; +import java.util.Map; + +import org.junit.Test; + +public class ObjectInstance_Test { + + ObjectInstance_ oi = new ObjectInstance_(); + Object value; + Map<String, Object> additionalProperties = new HashMap<String, Object>(); + @Test + public void test() { + + oi.setAdditionalProperty("name", value); + additionalProperties.put("name", value); + assertEquals(additionalProperties, oi.getAdditionalProperties()); + assert(oi.toString()!=null); + assert(oi.hashCode()!=0); + assertEquals(true, oi.equals(oi)); + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/ObjectKeyTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/ObjectKeyTest.java new file mode 100644 index 0000000..8aaab6e --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/ObjectKeyTest.java @@ -0,0 +1,54 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import static org.junit.Assert.*; + +import java.util.HashMap; +import java.util.Map; + +import org.junit.Test; + +public class ObjectKeyTest { + ObjectKey ok = new ObjectKey(); + Long l; + Object value; + Map<String, Object> additionalProperties = new HashMap<String, Object>(); + + @Test + public void testObjectKey() { + ok.setKeyName("keyName"); + ok.setKeyOrder(l); + ok.setKeyValue("keyValue"); + ok.setAdditionalProperty("name", value); + + assertEquals(ok.getKeyName(), "keyName"); + assertEquals(ok.getKeyOrder(), l); + assertEquals(ok.getKeyValue(), "keyValue"); + additionalProperties.put("name", value); + assertEquals(additionalProperties, ok.getAdditionalProperties()); + assert(ok.toString()!=null); + + assert(ok.hashCode()!=0); + assertEquals(true, ok.equals(ok)); + + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/OtherFieldsTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/OtherFieldsTest.java new file mode 100644 index 0000000..52332c6 --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/OtherFieldsTest.java @@ -0,0 +1,65 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import static org.junit.Assert.*; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import org.junit.Test; +import org.mockito.Mock; +import org.springframework.beans.factory.annotation.Autowired; + +public class OtherFieldsTest { + + @Autowired + OtherFields otherFields = new OtherFields(); + Object value = new Object();// = new Object(); + @Mock + List<JsonObject> jsonObjects; + @Mock + List<HashOfNameValuePairArray> hashOfNameValuePairArrays; + + @Mock + List<NameValuePair> nameValuePairs; + private Map<String, Object> additionalProperties = new HashMap<String, Object>(); + @Test + public void test() { + + otherFields.setAdditionalProperty("name", value); + otherFields.setHashOfNameValuePairArrays(hashOfNameValuePairArrays); + otherFields.setJsonObjects(jsonObjects); + otherFields.setNameValuePairs(nameValuePairs); + otherFields.setOtherFieldsVersion(2.2); + additionalProperties.put("name", value); + + assertEquals(hashOfNameValuePairArrays, otherFields.getHashOfNameValuePairArrays()); + assertEquals(jsonObjects, otherFields.getJsonObjects()); + assertEquals(nameValuePairs, otherFields.getNameValuePairs()); + assertEquals(new Double(2.2), otherFields.getOtherFieldsVersion()); + assertEquals(additionalProperties,otherFields.getAdditionalProperties() ); + + + + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/SipSignalingFieldsTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/SipSignalingFieldsTest.java new file mode 100644 index 0000000..2809c4d --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/SipSignalingFieldsTest.java @@ -0,0 +1,75 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import static org.junit.Assert.*; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import org.junit.Test; +import org.mockito.Mock; +import org.springframework.beans.factory.annotation.Autowired; + +public class SipSignalingFieldsTest { + + @Autowired + SipSignalingFields sipSignalingFields = new SipSignalingFields(); + List<AdditionalInformation> additionalInformation; + Object value; + Map<String, Object> additionalProperties = new HashMap<String, Object>(); + @Mock + VendorVnfNameFields vendorVnfNameFields; + + @Test + public void test() { + sipSignalingFields.setAdditionalInformation(additionalInformation); + sipSignalingFields.setAdditionalProperty("name", value); + sipSignalingFields.setCompressedSip("compressedSip"); + sipSignalingFields.setCorrelator("correlator"); + sipSignalingFields.setLocalIpAddress("localIpAddress"); + sipSignalingFields.setLocalPort("localPort"); + sipSignalingFields.setRemoteIpAddress("remoteIpAddress"); + sipSignalingFields.setRemotePort("remotePort"); + sipSignalingFields.setSipSignalingFieldsVersion(2.2); + sipSignalingFields.setSummarySip("summarySip"); + sipSignalingFields.setVendorVnfNameFields(vendorVnfNameFields); + additionalProperties.put("name", value); + + assertEquals(additionalInformation, sipSignalingFields.getAdditionalInformation()); + assertEquals(additionalInformation, sipSignalingFields.getAdditionalInformation()); + assertEquals("compressedSip", sipSignalingFields.getCompressedSip()); + assertEquals("correlator", sipSignalingFields.getCorrelator()); + assertEquals("localIpAddress", sipSignalingFields.getLocalIpAddress()); + assertEquals("localPort", sipSignalingFields.getLocalPort()); + assertEquals("remoteIpAddress", sipSignalingFields.getRemoteIpAddress()); + assertEquals("remotePort", sipSignalingFields.getRemotePort()); + assertEquals(new Double(2.2), sipSignalingFields.getSipSignalingFieldsVersion()); + assertEquals("summarySip", sipSignalingFields.getSummarySip()); + assertEquals(vendorVnfNameFields, sipSignalingFields.getVendorVnfNameFields()); + assert (sipSignalingFields.toString() != null); + assert (sipSignalingFields.hashCode() != 0); + assertEquals(true,sipSignalingFields.equals(sipSignalingFields)); + + + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/StateChangeFieldsTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/StateChangeFieldsTest.java new file mode 100644 index 0000000..93cee2d --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/StateChangeFieldsTest.java @@ -0,0 +1,61 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import static org.junit.Assert.*; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import org.junit.Test; +import org.mockito.Mock; +import org.springframework.beans.factory.annotation.Autowired; + +public class StateChangeFieldsTest { + @Autowired + StateChangeFields stateChangeFields = new StateChangeFields(); + @Mock + List<AdditionalField> additionalFields; + Map<String, Object> additionalProperties = new HashMap<String, Object>(); + Object value; + + @Test + public void test() { + stateChangeFields.setAdditionalFields(additionalFields); + stateChangeFields.setAdditionalProperty("name", value); + stateChangeFields.setNewState("newState"); + stateChangeFields.setOldState("oldState"); + stateChangeFields.setStateChangeFieldsVersion(2.2); + stateChangeFields.setStateInterface("stateInterface"); + additionalProperties.put("name", value); + assertEquals(additionalFields, stateChangeFields.getAdditionalFields()); + assertEquals(additionalProperties, stateChangeFields.getAdditionalProperties()); + assertEquals("newState", stateChangeFields.getNewState()); + assertEquals("oldState", stateChangeFields.getOldState()); + assertEquals(new Double(2.2), stateChangeFields.getStateChangeFieldsVersion()); + assertEquals("stateInterface", stateChangeFields.getStateInterface()); + assert (stateChangeFields.toString() != null); + assert (stateChangeFields.hashCode() != 0); + assertEquals(true, stateChangeFields.equals(stateChangeFields)); + + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/SyslogFieldsTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/SyslogFieldsTest.java new file mode 100644 index 0000000..8159651 --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/SyslogFieldsTest.java @@ -0,0 +1,76 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import static org.junit.Assert.*; + +import java.util.HashMap; +import java.util.Map; + +import org.junit.Test; +import org.springframework.beans.factory.annotation.Autowired; + +public class SyslogFieldsTest { + + @Autowired + SyslogFields syslogFields = new SyslogFields(); + Object value; + Map<String, Object> additionalProperties = new HashMap<String, Object>(); + @Test + public void test() { + syslogFields.setAdditionalFields("additionalFields"); + syslogFields.setAdditionalProperty("name", value); + syslogFields.setEventSourceHost("eventSourceHost"); + syslogFields.setEventSourceType("eventSourceType"); + syslogFields.setSyslogFacility(1L); + syslogFields.setSyslogFieldsVersion(2.2); + syslogFields.setSyslogMsg("syslogMsg"); + syslogFields.setSyslogPri(1L); + syslogFields.setSyslogProc("syslogProc"); + syslogFields.setSyslogProcId(2.2); + syslogFields.setSyslogSData("syslogSData"); + syslogFields.setSyslogSdId("syslogSdId"); + syslogFields.setSyslogSdId("syslogSdId"); + syslogFields.setSyslogSev("syslogSev"); + syslogFields.setSyslogTag("syslogTag"); + syslogFields.setSyslogVer(2.2); + additionalProperties.put("name", value); + assertEquals("additionalFields", syslogFields.getAdditionalFields()); + assertEquals(additionalProperties, syslogFields.getAdditionalProperties()); + assertEquals("eventSourceHost", syslogFields.getEventSourceHost()); + assertEquals("eventSourceType", syslogFields.getEventSourceType()); + assertEquals(new Long(1L), syslogFields.getSyslogFacility()); + assertEquals(new Double(2.2), syslogFields.getSyslogProcId()); + assertEquals(new Long(1L), syslogFields.getSyslogPri()); + assertEquals("syslogMsg", syslogFields.getSyslogMsg()); + assertEquals(new Long(1L), syslogFields.getSyslogPri()); + assertEquals("syslogProc", syslogFields.getSyslogProc()); + assertEquals("syslogSData", syslogFields.getSyslogSData()); + assertEquals("syslogSdId", syslogFields.getSyslogSdId()); + assertEquals("syslogTag", syslogFields.getSyslogTag()); + assertEquals("syslogSev", syslogFields.getSyslogSev()); + assertEquals(new Double(2.2), syslogFields.getSyslogVer()); + assert (syslogFields.toString() != null); + assert (syslogFields.hashCode() != 0); + assertEquals(true,syslogFields.equals(syslogFields)); + + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/ThresholdCrossingAlertFieldsTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/ThresholdCrossingAlertFieldsTest.java new file mode 100644 index 0000000..5c6b746 --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/ThresholdCrossingAlertFieldsTest.java @@ -0,0 +1,86 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import static org.junit.Assert.*; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import org.junit.Test; +import org.springframework.beans.factory.annotation.Autowired; + +public class ThresholdCrossingAlertFieldsTest { + + @Autowired + ThresholdCrossingAlertFields thresholdCrossingAlertFields =new ThresholdCrossingAlertFields(); + List<String> associatedAlertIdList; + List<AdditionalParameter> additionalParameters; + List<AdditionalField> additionalFields; + Map<String, Object> additionalProperties = new HashMap<String, Object>(); + Object value; + @Test + public void test() { + thresholdCrossingAlertFields.setAdditionalFields(additionalFields); + thresholdCrossingAlertFields.setAdditionalParameters(additionalParameters); + thresholdCrossingAlertFields.setAdditionalProperty("name", value); + thresholdCrossingAlertFields.setAlertAction("test"); + thresholdCrossingAlertFields.setAlertDescription("test"); + thresholdCrossingAlertFields.setAlertType("test"); + thresholdCrossingAlertFields.setAlertValue("test"); + thresholdCrossingAlertFields.setAssociatedAlertIdList(associatedAlertIdList); + thresholdCrossingAlertFields.setCollectionTimestamp("test"); + thresholdCrossingAlertFields.setDataCollector("test"); + thresholdCrossingAlertFields.setElementType("test"); + thresholdCrossingAlertFields.setEventSeverity("test"); + thresholdCrossingAlertFields.setEventStartTimestamp("test"); + thresholdCrossingAlertFields.setInterfaceName("test"); + thresholdCrossingAlertFields.setNetworkService("test"); + thresholdCrossingAlertFields.setPossibleRootCause("test"); + thresholdCrossingAlertFields.setThresholdCrossingFieldsVersion(2.2); + + additionalProperties.put("name", value); + assertEquals(additionalFields, thresholdCrossingAlertFields.getAdditionalFields()); + assertEquals("test", thresholdCrossingAlertFields.getAlertAction()); + assertEquals("test", thresholdCrossingAlertFields.getAlertDescription()); + assertEquals("test", thresholdCrossingAlertFields.getAlertType()); + assertEquals("test", thresholdCrossingAlertFields.getAlertValue()); + assertEquals("test", thresholdCrossingAlertFields.getCollectionTimestamp()); + assertEquals("test", thresholdCrossingAlertFields.getDataCollector()); + assertEquals("test", thresholdCrossingAlertFields.getElementType()); + assertEquals("test", thresholdCrossingAlertFields.getEventSeverity()); + assertEquals("test", thresholdCrossingAlertFields.getEventStartTimestamp()); + assertEquals("test", thresholdCrossingAlertFields.getInterfaceName()); + assertEquals("test", thresholdCrossingAlertFields.getNetworkService()); + assertEquals("test", thresholdCrossingAlertFields.getPossibleRootCause()); + assertEquals(new Double(2.2), thresholdCrossingAlertFields.getThresholdCrossingFieldsVersion()); + assertEquals(associatedAlertIdList, thresholdCrossingAlertFields.getAssociatedAlertIdList()); + assertEquals(additionalProperties, thresholdCrossingAlertFields.getAdditionalProperties()); + assertEquals(additionalParameters, thresholdCrossingAlertFields.getAdditionalParameters()); + + + + + + + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/VendorVnfNameFieldsTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/VendorVnfNameFieldsTest.java new file mode 100644 index 0000000..bc7d3bd --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/VendorVnfNameFieldsTest.java @@ -0,0 +1,52 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import static org.junit.Assert.*; + +import java.util.HashMap; +import java.util.Map; + +import org.junit.Test; +import org.springframework.beans.factory.annotation.Autowired; + +public class VendorVnfNameFieldsTest { + + @Autowired + VendorVnfNameFields vendorVnfNameFields = new VendorVnfNameFields(); + Object value; + Map<String, Object> additionalProperties = new HashMap<String, Object>(); + @Test + public void test() { + vendorVnfNameFields.setAdditionalProperty("name", value); + vendorVnfNameFields.setVendorName("testvendorname"); + vendorVnfNameFields.setVfModuleName("vfModuleName"); + vendorVnfNameFields.setVnfName("vnfName"); + additionalProperties.put("name", value); + assertEquals(additionalProperties, vendorVnfNameFields.getAdditionalProperties()); + assertEquals("testvendorname", vendorVnfNameFields.getVendorName()); + assertEquals("vfModuleName", vendorVnfNameFields.getVfModuleName()); + assertEquals("vnfName", vendorVnfNameFields.getVnfName()); + + + + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/VoiceQualityFieldsTest.java b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/VoiceQualityFieldsTest.java new file mode 100644 index 0000000..9a5711a --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/dcaegen2/ves/domain/VoiceQualityFieldsTest.java @@ -0,0 +1,72 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.dcaegen2.ves.domain; + +import static org.junit.Assert.*; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import org.onap.dcaegen2.ves.domain.VoiceQualityFields; +import org.junit.Test; +import org.mockito.Mock; +import org.springframework.beans.factory.annotation.Autowired; + +public class VoiceQualityFieldsTest { + + @Autowired + VoiceQualityFields voiceQualityFields =new VoiceQualityFields(); + @Mock + VendorVnfNameFields vendorVnfNameFields; + @Mock + EndOfCallVqmSummaries endOfCallVqmSummaries; + List<AdditionalInformation> additionalInformation; + Object value; + Map<String, Object> additionalProperties = new HashMap<String, Object>(); + @Test + public void test() { + voiceQualityFields.setAdditionalInformation(additionalInformation); + voiceQualityFields.setAdditionalProperty("name", value); + voiceQualityFields.setCalleeSideCodec("test"); + voiceQualityFields.setCallerSideCodec("test"); + voiceQualityFields.setCorrelator("test"); + voiceQualityFields.setEndOfCallVqmSummaries(endOfCallVqmSummaries); + voiceQualityFields.setMidCallRtcp("test"); + voiceQualityFields.setPhoneNumber("test"); + voiceQualityFields.setVendorVnfNameFields(vendorVnfNameFields); + voiceQualityFields.setVoiceQualityFieldsVersion(2.2); + additionalProperties.put("name", value); + + assertEquals("test", voiceQualityFields.getCalleeSideCodec()); + assertEquals("test", voiceQualityFields.getCallerSideCodec()); + assertEquals("test", voiceQualityFields.getCorrelator()); + assertEquals("test", voiceQualityFields.getMidCallRtcp()); + assertEquals("test", voiceQualityFields.getPhoneNumber()); + assertEquals(additionalProperties, voiceQualityFields.getAdditionalProperties()); + assertEquals(endOfCallVqmSummaries, voiceQualityFields.getEndOfCallVqmSummaries()); + assertEquals(vendorVnfNameFields, voiceQualityFields.getVendorVnfNameFields()); + assertEquals(additionalInformation, voiceQualityFields.getAdditionalInformation()); + + + + + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/universalvesadapter/adapter/UniversalEventAdapterTest.java b/UniversalVesAdapter/src/test/java/org/onap/universalvesadapter/adapter/UniversalEventAdapterTest.java new file mode 100644 index 0000000..bc2cf4f --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/universalvesadapter/adapter/UniversalEventAdapterTest.java @@ -0,0 +1,162 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.universalvesadapter.adapter; + +import static org.junit.Assert.*; +import static org.mockito.Mockito.when; + +import java.io.FileNotFoundException; +import java.io.FileReader; +import java.io.IOException; +import java.util.Arrays; +import java.util.Collections; +import java.util.Map; +import java.util.concurrent.ConcurrentHashMap; + +import javax.annotation.Resource; + +import org.junit.Before; +import org.junit.BeforeClass; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.milyn.Smooks; +import org.mockito.InjectMocks; +import org.mockito.Mock; +import org.mockito.Mockito; +import org.mockito.MockitoAnnotations; +import org.onap.dcaegen2.ves.domain.VesEvent; +import org.onap.universalvesadapter.Application; +import org.onap.universalvesadapter.adapter.UniversalEventAdapter; +import org.onap.universalvesadapter.exception.ConfigFileReadException; +import org.onap.universalvesadapter.exception.ConfigFileSmooksConversionException; +import org.onap.universalvesadapter.exception.MapperConfigException; +import org.onap.universalvesadapter.exception.VesException; +import org.onap.universalvesadapter.service.ConfigFileService; +import org.onap.universalvesadapter.utils.MapperConfigUtils; +import org.onap.universalvesadapter.utils.SmooksUtils; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.beans.factory.annotation.Value; +import org.springframework.boot.test.context.SpringBootTest; +import org.springframework.test.context.junit4.SpringRunner; +import org.springframework.util.FileCopyUtils; + +import com.fasterxml.jackson.core.JsonProcessingException; +import com.fasterxml.jackson.databind.ObjectMapper; + +@RunWith(SpringRunner.class) +@SpringBootTest(classes=Application.class) +public class UniversalEventAdapterTest { + + private final Logger eLOGGER = LoggerFactory.getLogger(this.getClass()); + + @Mock + private ConfigFileService configFileService; + + @InjectMocks + @Autowired + private UniversalEventAdapter universalVesAdapter; + + + @Before + public void init() { + MockitoAnnotations.initMocks(this); + } + + + @Test + public void testtransform() { + StringBuffer incomingJsonString = new StringBuffer("{ ") + .append("\"protocol version\":\"v2c\", ") + .append("\"notify OID\":\".1.3.6.1.4.1.74.2.46.12.1.1AAA\", ") + .append("\"cambria.partition\":\"dcae-snmp.client.research.att.com\", ") + .append("\"trap category\":\"UCSNMP-HEARTBEAT\", ") + .append("\"epoch_serno\": 15161177410000, ") + .append("\"community\":\"public\", ") + .append("\"time received\": 1516117741, ") + .append("\"agent name\":\"localhost\", ") + .append("\"agent address\":\"127.0.0.1\", ") + .append("\"community len\": 6, ") + .append("\"notify OID len\": 12, ") + .append("\"varbinds\": [{ ") + .append(" \"varbind_type\":\"octet\", ") + .append(" \"varbind_oid\":\".1.3.6.1.4.1.74.2.46.12.1.1.1\", ") + .append(" \"varbind_value\":\"ucsnmp heartbeat - ignore\" ") + .append(" }, { ") + .append(" \"varbind_type\":\"octet\", ") + .append(" \"varbind_oid\":\".1.3.6.1.4.1.74.2.46.12.1.1.2\", ") + .append(" \"varbind_value\":\"Tue Jan 16 10:49:01 EST 2018\" ") + .append(" }] ") + .append("}"); + + StringBuffer configFileData = new StringBuffer("<?xml version=\"1.0\" encoding=\"UTF-8\"?> ") + .append("<smooks-resource-list xmlns=\"http://www.milyn.org/xsd/smooks-1.1.xsd\" ") + .append("xmlns:json=\"http://www.milyn.org/xsd/smooks/json-1.1.xsd\" ") + .append(" xmlns:jb=\"http://www.milyn.org/xsd/smooks/javabean-1.2.xsd\"> ") + .append(" <json:reader rootName=\"simple\" keyWhitspaceReplacement=\"-\"> ") + .append(" </json:reader> ") + .append(" <jb:bean class=\"org.onap.dcaegen2.ves.domain.VesEvent\" beanId=\"vesEvent\" ") + .append(" createOnElement=\"simple\">") + .append(" <jb:wiring property=\"event\" beanIdRef=\"event\"/>") + .append(" </jb:bean> ") + .append(" <jb:bean class=\"org.onap.dcaegen2.ves.domain.Event\" beanId=\"event\" ") + .append(" createOnElement=\"simple\"> ") + .append(" <jb:wiring property=\"commonEventHeader\" beanIdRef=\"commonEventHeader\"/>") + .append(" <jb:wiring property=\"faultFields\" beanIdRef=\"faultFields\"/> ") + .append(" </jb:bean> ") + .append(" <jb:bean class=\"org.onap.dcaegen2.ves.domain.CommonEventHeader\" ") + .append(" beanId=\"commonEventHeader\" createOnElement=\"simple\"> ") + .append(" <jb:value property=\"eventId\" data=\"#/community\" /> ") + .append(" <jb:value property=\"eventName\" data=\"#/protocol-version\" /> ") + .append(" <jb:value property=\"domain\" data=\"#/trap-category\" /> ") + .append(" <jb:value property=\"sequence\" data=\"#/time-received\" decoder=\"Long\"/> ") + .append(" <jb:value property=\"lastEpochMicrosec\" data=\"#/community-len\" decoder=\"Double\" /> ") + .append(" <jb:value property=\"startEpochMicrosec\" data=\"#/notify-OID-len\" /> ") + .append(" </jb:bean> ") + .append(" <jb:bean class=\"org.onap.dcaegen2.ves.domain.FaultFields\" beanId=\"faultFields\"") + .append(" createOnElement=\"simple\"> <jb:value property=\"alarmCondition\" data=\"#/cambria.partition\" /> ") + .append(" <jb:value property=\"eventSeverity\" data=\"#/notify-OID\" /> ") + .append(" <jb:value property=\"eventSourceType\" data=\"#/agent-name\" /> ") + .append(" <jb:value property=\"specificProblem\" data=\"#/agent-address\" /> ") + .append(" <jb:value property=\"faultFieldsVersion\" data=\"#/epoch_serno\" decoder=\"Double\" /> ") + .append(" </jb:bean> ") + .append("</smooks-resource-list>"); + + try { + Mockito.when(configFileService.readConfigFile(Mockito.anyString())).thenReturn(configFileData.toString()); + } catch (Exception e) { + eLOGGER.error("Error occurred : " + e.getMessage()); + } + + + try { + String actualResult = universalVesAdapter.transform(incomingJsonString.toString(), "snmp"); + assertNotNull(actualResult); + assertNotEquals("", actualResult); + } catch (VesException exception) { + eLOGGER.error("Error occurred : ", exception ); + } + } + + + + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/universalvesadapter/service/AdapterServiceTest.java b/UniversalVesAdapter/src/test/java/org/onap/universalvesadapter/service/AdapterServiceTest.java index 720a7d1..298ab69 100644 --- a/UniversalVesAdapter/src/test/java/org/onap/universalvesadapter/service/AdapterServiceTest.java +++ b/UniversalVesAdapter/src/test/java/org/onap/universalvesadapter/service/AdapterServiceTest.java @@ -65,7 +65,7 @@ public class AdapterServiceTest { @Value("${mapperConfig.file}") private String mapperConfigFile; - /* @Test + @Test public void identifyEventTypeFromIncomingJson() throws MapperConfigException, FileNotFoundException, IOException { String inputJsonString = "{ " @@ -93,15 +93,29 @@ public class AdapterServiceTest { String domain = ""; - String mappingConfigFileData = FileCopyUtils.copyToString(new FileReader(mapperConfigFile)); - MapperConfigUtils.readMapperConfigFile(mappingConfigFileData); + String mappingFileContent = "{" + " \"entries\" : [" + + " {" + + " \"priority\" : 1," + + " \"evaluation\" : {" + + " \"operand\" : \"STARTSWITH\"," + + " \"field\" : \"notify OID\"," + + " \"value\" : \".1.3.6.1.4.1.74\"," + + " \"datatype\" : \"STRING\"," + + " \"lhs\" : null," + + " \"rhs\" : null " + + " }," + + " \"result\" : \"snmp\"" + + " } " + + " ]" + + "}"; + MapperConfigUtils.readMapperConfigFile(mappingFileContent); domain = adapterService.identifyEventTypeFromIncomingJson(inputJsonString); adapterService.identifyEventTypeFromIncomingJson(inputJsonString); assertEquals("snmp", domain); - }*/ - @Test + } + /*@Test public void testidentifyEventTypeFromIncomingJson() throws MapperConfigException{ String inputJsonString = "{ " + "\"protocol version\":\"v2c\", " @@ -128,6 +142,6 @@ public class AdapterServiceTest { // when(MapperConfigUtils.checkIncomingJsonForMatchingDomain(inputJsonString)).thenReturn("snmp"); String actualDomain=adapterService.identifyEventTypeFromIncomingJson(inputJsonString); assertEquals("default", actualDomain); - } + }*/ } diff --git a/UniversalVesAdapter/src/test/java/org/onap/universalvesadapter/utils/MapperConfigUtilsTest.java b/UniversalVesAdapter/src/test/java/org/onap/universalvesadapter/utils/MapperConfigUtilsTest.java new file mode 100644 index 0000000..85015da --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/universalvesadapter/utils/MapperConfigUtilsTest.java @@ -0,0 +1,93 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.universalvesadapter.utils; + +import static org.junit.Assert.*; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.verify; + +import java.util.Set; +import java.util.TreeSet; + +import org.junit.Test; +import org.onap.universalvesadapter.exception.MapperConfigException; +import org.onap.universalvesadapter.mappingconfig.Entry; +import org.onap.universalvesadapter.mappingconfig.Evaluation; +import org.onap.universalvesadapter.mappingconfig.MapperConfig; +import org.onap.universalvesadapter.utils.MapperConfigUtils; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import com.fasterxml.jackson.databind.JsonNode; + +public class MapperConfigUtilsTest { + + private final Logger eLOGGER = LoggerFactory.getLogger(this.getClass()); + + String mappingFileContent = "{" + " \"entries\" : [" + + " {" + + " \"priority\" : 1," + + " \"evaluation\" : {" + + " \"operand\" : \"STARTSWITH\"," + + " \"field\" : \"notify OID\"," + + " \"value\" : \".1.3.6.1.4.1.74\"," + + " \"datatype\" : \"STRING\"," + + " \"lhs\" : null," + + " \"rhs\" : null " + + " }," + + " \"result\" : \"snmp\"" + + " } " + + " ]" + + "}"; + + String inputJsonString = "{ " + "\"protocol version\":\"v2c\", " + + "\"notify OID\":\".1.3.6.1.4.1.74.2.46.12.1.1AAA\", " + + "\"cambria.partition\":\"dcae-snmp.client.research.att.com\", " + + "\"trap category\":\"UCSNMP-HEARTBEAT\", " + + "\"epoch_serno\": 15161177410000, " + + "\"community\":\"public\", " + + "\"time received\": 1516117741, " + + "\"agent name\":\"localhost\", " + + "\"agent address\":\"127.0.0.1\", " + + "\"community len\": 6, " + + "\"notify OID len\": 12, " + + "\"varbinds\": [{ " + + " \"varbind_type\":\"octet\", " + + " \"varbind_oid\":\".1.3.6.1.4.1.74.2.46.12.1.1.1\", " + + " \"varbind_value\":\"ucsnmp heartbeat - ignore\" " + + " }, { " + " \"varbind_type\":\"octet\", " + + " \"varbind_oid\":\".1.3.6.1.4.1.74.2.46.12.1.1.2\", " + + " \"varbind_value\":\"Tue Jan 16 10:49:01 EST 2018\" " + + " }] " + "}"; + + @Test + public void checkIncomingJsonForMatchingDomainTest() throws MapperConfigException { + try { + MapperConfigUtils.readMapperConfigFile(mappingFileContent); + String checkIncomingJsonForMatchingDomain = MapperConfigUtils + .checkIncomingJsonForMatchingDomain(inputJsonString); + assertEquals("snmp", checkIncomingJsonForMatchingDomain); + } catch (MapperConfigException exception) { + eLOGGER.error("Error occurred : ", exception ); + } + + } + +} diff --git a/UniversalVesAdapter/src/test/java/org/onap/universalvesadapter/utils/SmooksUtilsTest.java b/UniversalVesAdapter/src/test/java/org/onap/universalvesadapter/utils/SmooksUtilsTest.java new file mode 100644 index 0000000..41431f7 --- /dev/null +++ b/UniversalVesAdapter/src/test/java/org/onap/universalvesadapter/utils/SmooksUtilsTest.java @@ -0,0 +1,134 @@ +/* +* ============LICENSE_START======================================================= +* ONAP : DCAE +* ================================================================================ +* Copyright 2018 TechMahindra +*================================================================================= +* 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. +* ============LICENSE_END========================================================= +*/ +package org.onap.universalvesadapter.utils; + +import static org.junit.Assert.*; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.when; + +import java.beans.beancontext.BeanContext; +import java.io.ByteArrayInputStream; +import java.io.FileNotFoundException; +import java.io.FileReader; +import java.io.IOException; +import java.nio.charset.StandardCharsets; + +import org.junit.Before; +import org.junit.BeforeClass; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.milyn.Smooks; +import org.milyn.container.ExecutionContext; +import org.mockito.InjectMocks; +import org.mockito.Mock; +import org.mockito.MockitoAnnotations; +import org.mockito.junit.MockitoJUnitRunner; +import org.onap.dcaegen2.ves.domain.VesEvent; +import org.onap.universalvesadapter.exception.MapperConfigException; +import org.onap.universalvesadapter.utils.SmooksUtils; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import org.springframework.beans.factory.annotation.Value; +import org.springframework.util.FileCopyUtils; +import org.xml.sax.SAXException; + +public class SmooksUtilsTest { + + private final Logger eLOGGER = LoggerFactory.getLogger(this.getClass()); + + @Test + public void testGetTransformedObjectForInput() { + StringBuffer incomingJsonString = new StringBuffer("{ ") + .append("\"protocol version\":\"v2c\", ") + .append("\"notify OID\":\".1.3.6.1.4.1.74.2.46.12.1.1AAA\", ") + .append("\"cambria.partition\":\"dcae-snmp.client.research.att.com\", ") + .append("\"trap category\":\"UCSNMP-HEARTBEAT\", ") + .append("\"epoch_serno\": 15161177410000, ") + .append("\"community\":\"public\", ") + .append("\"time received\": 1516117741, ") + .append("\"agent name\":\"localhost\", ") + .append("\"agent address\":\"127.0.0.1\", ") + .append("\"community len\": 6, ") + .append("\"notify OID len\": 12, ") + .append("\"varbinds\": [{ ") + .append(" \"varbind_type\":\"octet\", ") + .append(" \"varbind_oid\":\".1.3.6.1.4.1.74.2.46.12.1.1.1\", ") + .append(" \"varbind_value\":\"ucsnmp heartbeat - ignore\" ") + .append(" }, { ") + .append(" \"varbind_type\":\"octet\", ") + .append(" \"varbind_oid\":\".1.3.6.1.4.1.74.2.46.12.1.1.2\", ") + .append(" \"varbind_value\":\"Tue Jan 16 10:49:01 EST 2018\" ") + .append(" }] ") + .append("}"); + StringBuffer configFileData = new StringBuffer("<?xml version=\"1.0\" encoding=\"UTF-8\"?> ") + .append("<smooks-resource-list xmlns=\"http://www.milyn.org/xsd/smooks-1.1.xsd\" ") + .append("xmlns:json=\"http://www.milyn.org/xsd/smooks/json-1.1.xsd\" ") + .append(" xmlns:jb=\"http://www.milyn.org/xsd/smooks/javabean-1.2.xsd\"> ") + .append(" <json:reader rootName=\"simple\" keyWhitspaceReplacement=\"-\"> ") + .append(" </json:reader> ") + .append(" <jb:bean class=\"org.onap.dcaegen2.ves.domain.VesEvent\" beanId=\"vesEvent\" ") + .append(" createOnElement=\"simple\">") + .append(" <jb:wiring property=\"event\" beanIdRef=\"event\"/>") + .append(" </jb:bean> ") + .append(" <jb:bean class=\"org.onap.dcaegen2.ves.domain.Event\" beanId=\"event\" ") + .append(" createOnElement=\"simple\"> ") + .append(" <jb:wiring property=\"commonEventHeader\" beanIdRef=\"commonEventHeader\"/>") + .append(" <jb:wiring property=\"faultFields\" beanIdRef=\"faultFields\"/> ") + .append(" </jb:bean> ") + .append(" <jb:bean class=\"org.onap.dcaegen2.ves.domain.CommonEventHeader\" ") + .append(" beanId=\"commonEventHeader\" createOnElement=\"simple\"> ") + .append(" <jb:value property=\"eventId\" data=\"#/community\" /> ") + .append(" <jb:value property=\"eventName\" data=\"#/protocol-version\" /> ") + .append(" <jb:value property=\"domain\" data=\"#/trap-category\" /> ") + .append(" <jb:value property=\"sequence\" data=\"#/time-received\" decoder=\"Long\"/> ") + .append(" <jb:value property=\"lastEpochMicrosec\" data=\"#/community-len\" decoder=\"Double\" /> ") + .append(" <jb:value property=\"startEpochMicrosec\" data=\"#/notify-OID-len\" /> ") + .append(" </jb:bean> ") + .append(" <jb:bean class=\"org.onap.dcaegen2.ves.domain.FaultFields\" beanId=\"faultFields\"") + .append(" createOnElement=\"simple\"> <jb:value property=\"alarmCondition\" data=\"#/cambria.partition\" /> ") + .append(" <jb:value property=\"eventSeverity\" data=\"#/notify-OID\" /> ") + .append(" <jb:value property=\"eventSourceType\" data=\"#/agent-name\" /> ") + .append(" <jb:value property=\"specificProblem\" data=\"#/agent-address\" /> ") + .append(" <jb:value property=\"faultFieldsVersion\" data=\"#/epoch_serno\" decoder=\"Double\" /> ") + .append(" </jb:bean> ") + .append("</smooks-resource-list>"); + + Smooks smooks = null; + VesEvent vesEvent = new VesEvent(); + try { + //reading config file.. for now, looking at it as just one time operation + if(null == smooks){ + + smooks = new Smooks(new ByteArrayInputStream( + configFileData.toString().getBytes(StandardCharsets.UTF_8))); + } + + vesEvent = SmooksUtils.getTransformedObjectForInput(smooks, + incomingJsonString.toString()); + } catch (IOException | SAXException exception) { + eLOGGER.error("Error occurred : ", exception ); + } + + assertEquals(vesEvent.getEvent().getCommonEventHeader().getDomain(), "UCSNMP-HEARTBEAT"); + + + } + +} |