http://git-wip-us.apache.org/repos/asf/atlas/blob/75415862/intg/src/main/java/org/apache/atlas/model/glossary/AtlasGlossaryTerm.java ---------------------------------------------------------------------- diff --git a/intg/src/main/java/org/apache/atlas/model/glossary/AtlasGlossaryTerm.java b/intg/src/main/java/org/apache/atlas/model/glossary/AtlasGlossaryTerm.java new file mode 100644 index 0000000..f42bf35 --- /dev/null +++ b/intg/src/main/java/org/apache/atlas/model/glossary/AtlasGlossaryTerm.java @@ -0,0 +1,453 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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 + * <p> + * http://www.apache.org/licenses/LICENSE-2.0 + * <p> + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.atlas.model.glossary; + +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonValue; +import org.apache.atlas.model.annotation.AtlasJSON; +import org.apache.atlas.model.glossary.relations.AtlasGlossaryHeader; +import org.apache.atlas.model.glossary.relations.AtlasRelatedTermHeader; +import org.apache.atlas.model.glossary.relations.AtlasTermCategorizationHeader; +import org.apache.atlas.model.instance.AtlasEntityHeader; +import org.apache.commons.collections.CollectionUtils; + +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +@AtlasJSON +public class AtlasGlossaryTerm extends AtlasGlossaryBaseObject { + // Core attributes + private List<String> examples; + private String abbreviation; + private String usage; + + // Attributes derived from relationships + private AtlasGlossaryHeader anchor; + private Set<AtlasEntityHeader> assignedEntities; + private Set<AtlasTermCategorizationHeader> categories; + + // Related Terms + private Set<AtlasRelatedTermHeader> seeAlso; + + // Term Synonyms + private Set<AtlasRelatedTermHeader> synonyms; + + // Term antonyms + private Set<AtlasRelatedTermHeader> antonyms; + + // Term preference + private Set<AtlasRelatedTermHeader> preferredTerms; + private Set<AtlasRelatedTermHeader> preferredToTerms; + + // Term replacements + private Set<AtlasRelatedTermHeader> replacementTerms; + private Set<AtlasRelatedTermHeader> replacedBy; + + // Term translations + private Set<AtlasRelatedTermHeader> translationTerms; + private Set<AtlasRelatedTermHeader> translatedTerms; + + // Term classification + private Set<AtlasRelatedTermHeader> isA; + private Set<AtlasRelatedTermHeader> classifies; + + // Values for terms + private Set<AtlasRelatedTermHeader> validValues; + private Set<AtlasRelatedTermHeader> validValuesFor; + + private boolean hasTerms = false; + + public AtlasGlossaryTerm() { + } + + public List<String> getExamples() { + return examples; + } + + public void setExamples(final List<String> examples) { + this.examples = examples; + } + + public String getAbbreviation() { + return abbreviation; + } + + public void setAbbreviation(final String abbreviation) { + this.abbreviation = abbreviation; + } + + public String getUsage() { + return usage; + } + + public void setUsage(final String usage) { + this.usage = usage; + } + + public AtlasGlossaryHeader getAnchor() { + return anchor; + } + + public void setAnchor(final AtlasGlossaryHeader anchor) { + this.anchor = anchor; + } + + public Set<AtlasTermCategorizationHeader> getCategories() { + return categories; + } + + public void setCategories(final Set<AtlasTermCategorizationHeader> categories) { + this.categories = categories; + } + + public void addCategory(final AtlasTermCategorizationHeader category) { + Set<AtlasTermCategorizationHeader> categories = this.categories; + if (categories == null) { + categories = new HashSet<>(); + } + categories.add(category); + setCategories(categories); + } + + public Set<AtlasEntityHeader> getAssignedEntities() { + return assignedEntities; + } + + public void setAssignedEntities(final Set<AtlasEntityHeader> assignedEntities) { + this.assignedEntities = assignedEntities; + } + + public void addAssignedEntity(final AtlasEntityHeader entityHeader) { + Set<AtlasEntityHeader> entityHeaders = this.assignedEntities; + if (entityHeaders == null) { + entityHeaders = new HashSet<>(); + } + entityHeaders.add(entityHeader); + setAssignedEntities(entityHeaders); + } + + public Set<AtlasRelatedTermHeader> getSeeAlso() { + return seeAlso; + } + + public void setSeeAlso(final Set<AtlasRelatedTermHeader> seeAlso) { + this.seeAlso = seeAlso; + hasTerms = true; + } + + public Set<AtlasRelatedTermHeader> getSynonyms() { + return synonyms; + } + + public void setSynonyms(final Set<AtlasRelatedTermHeader> synonyms) { + this.synonyms = synonyms; + hasTerms = true; + } + + public Set<AtlasRelatedTermHeader> getAntonyms() { + return antonyms; + } + + public void setAntonyms(final Set<AtlasRelatedTermHeader> antonyms) { + this.antonyms = antonyms; + hasTerms = true; + } + + public Set<AtlasRelatedTermHeader> getPreferredTerms() { + return preferredTerms; + } + + public void setPreferredTerms(final Set<AtlasRelatedTermHeader> preferredTerms) { + this.preferredTerms = preferredTerms; + hasTerms = true; + } + + public Set<AtlasRelatedTermHeader> getPreferredToTerms() { + return preferredToTerms; + } + + public void setPreferredToTerms(final Set<AtlasRelatedTermHeader> preferredToTerms) { + this.preferredToTerms = preferredToTerms; + } + + public Set<AtlasRelatedTermHeader> getReplacementTerms() { + return replacementTerms; + } + + public void setReplacementTerms(final Set<AtlasRelatedTermHeader> replacementTerms) { + this.replacementTerms = replacementTerms; + hasTerms = true; + } + + public Set<AtlasRelatedTermHeader> getReplacedBy() { + return replacedBy; + } + + public void setReplacedBy(final Set<AtlasRelatedTermHeader> replacedBy) { + this.replacedBy = replacedBy; + hasTerms = true; + } + + public Set<AtlasRelatedTermHeader> getTranslationTerms() { + return translationTerms; + } + + public void setTranslationTerms(final Set<AtlasRelatedTermHeader> translationTerms) { + this.translationTerms = translationTerms; + hasTerms = true; + } + + public Set<AtlasRelatedTermHeader> getTranslatedTerms() { + return translatedTerms; + } + + public void setTranslatedTerms(final Set<AtlasRelatedTermHeader> translatedTerms) { + this.translatedTerms = translatedTerms; + hasTerms = true; + } + + public Set<AtlasRelatedTermHeader> getIsA() { + return isA; + } + + public void setIsA(final Set<AtlasRelatedTermHeader> isA) { + this.isA = isA; + hasTerms = true; + } + + public Set<AtlasRelatedTermHeader> getClassifies() { + return classifies; + } + + public void setClassifies(final Set<AtlasRelatedTermHeader> classifies) { + this.classifies = classifies; + hasTerms = true; + } + + public Set<AtlasRelatedTermHeader> getValidValues() { + return validValues; + } + + public void setValidValues(final Set<AtlasRelatedTermHeader> validValues) { + this.validValues = validValues; + hasTerms = true; + } + + public Set<AtlasRelatedTermHeader> getValidValuesFor() { + return validValuesFor; + } + + public void setValidValuesFor(final Set<AtlasRelatedTermHeader> validValuesFor) { + this.validValuesFor = validValuesFor; + hasTerms = true; + } + + @JsonIgnore + public boolean hasTerms() { + return hasTerms; + } + + @JsonIgnore + @Override + public void setAttribute(String attrName, String attrVal) { + Objects.requireNonNull(attrName, "AtlasGlossaryTerm attribute name"); + switch (attrName) { + case "displayName": + setDisplayName(attrVal); + break; + case "shortDescription": + setShortDescription(attrVal); + break; + case "longDescription": + setLongDescription(attrVal); + break; + case "abbreviation": + setAbbreviation(attrVal); + break; + case "usage": + setUsage(attrVal); + break; + default: + throw new IllegalArgumentException("Invalid attribute '" + attrName + "' for object AtlasGlossaryTerm"); + } + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("AtlasGlossaryTerm{"); + sb.append("examples=").append(examples); + sb.append(", abbreviation='").append(abbreviation).append('\''); + sb.append(", usage='").append(usage).append('\''); + sb.append(", anchor=").append(anchor); + sb.append(", assignedEntities=").append(assignedEntities); + sb.append(", categories=").append(categories); + sb.append(", seeAlso=").append(seeAlso); + sb.append(", synonyms=").append(synonyms); + sb.append(", antonyms=").append(antonyms); + sb.append(", preferredTerms=").append(preferredTerms); + sb.append(", preferredToTerms=").append(preferredToTerms); + sb.append(", replacementTerms=").append(replacementTerms); + sb.append(", replacedBy=").append(replacedBy); + sb.append(", translationTerms=").append(translationTerms); + sb.append(", translatedTerms=").append(translatedTerms); + sb.append(", isA=").append(isA); + sb.append(", classifies=").append(classifies); + sb.append(", validValues=").append(validValues); + sb.append(", validValuesFor=").append(validValuesFor); + sb.append(", hasTerms=").append(hasTerms); + sb.append('}'); + return sb.toString(); + } + + @JsonIgnore + public Map<Relation, Set<AtlasRelatedTermHeader>> getRelatedTerms() { + Map<Relation, Set<AtlasRelatedTermHeader>> ret = new HashMap<>(); + + if (CollectionUtils.isNotEmpty(seeAlso)) { + ret.put(Relation.SEE_ALSO, seeAlso); + } + + if (CollectionUtils.isNotEmpty(synonyms)) { + ret.put(Relation.SYNONYMS, synonyms); + } + + if (CollectionUtils.isNotEmpty(antonyms)) { + ret.put(Relation.ANTONYMS, antonyms); + } + + if (CollectionUtils.isNotEmpty(preferredTerms)) { + ret.put(Relation.PREFERRED_TERMS, preferredTerms); + } + + if (CollectionUtils.isNotEmpty(preferredToTerms)) { + ret.put(Relation.PREFERRED_TO_TERMS, preferredToTerms); + } + + if (CollectionUtils.isNotEmpty(replacementTerms)) { + ret.put(Relation.REPLACEMENT_TERMS, replacementTerms); + } + + if (CollectionUtils.isNotEmpty(replacedBy)) { + ret.put(Relation.REPLACED_BY, replacedBy); + } + + if (CollectionUtils.isNotEmpty(translationTerms)) { + ret.put(Relation.TRANSLATION_TERMS, translationTerms); + } + + if (CollectionUtils.isNotEmpty(translatedTerms)) { + ret.put(Relation.TRANSLATED_TERMS, translatedTerms); + } + + if (CollectionUtils.isNotEmpty(isA)) { + ret.put(Relation.ISA, isA); + } + + if (CollectionUtils.isNotEmpty(classifies)) { + ret.put(Relation.CLASSIFIES, classifies); + } + + if (CollectionUtils.isNotEmpty(validValues)) { + ret.put(Relation.VALID_VALUES, validValues); + } + + if (CollectionUtils.isNotEmpty(validValuesFor)) { + ret.put(Relation.VALID_VALUES_FOR, validValuesFor); + } + + return ret; + } + + @Override + protected StringBuilder toString(final StringBuilder sb) { + return sb == null ? new StringBuilder(toString()) : sb.append(toString()); + } + + @Override + public boolean equals(final Object o) { + if (this == o) return true; + if (!(o instanceof AtlasGlossaryTerm)) return false; + if (!super.equals(o)) return false; + final AtlasGlossaryTerm that = (AtlasGlossaryTerm) o; + return Objects.equals(examples, that.examples) && + Objects.equals(abbreviation, that.abbreviation) && + Objects.equals(usage, that.usage) && + Objects.equals(anchor, that.anchor) && + Objects.equals(assignedEntities, that.assignedEntities) && + Objects.equals(categories, that.categories) && + Objects.equals(seeAlso, that.seeAlso) && + Objects.equals(synonyms, that.synonyms) && + Objects.equals(antonyms, that.antonyms) && + Objects.equals(preferredTerms, that.preferredTerms) && + Objects.equals(preferredToTerms, that.preferredToTerms) && + Objects.equals(replacementTerms, that.replacementTerms) && + Objects.equals(replacedBy, that.replacedBy) && + Objects.equals(translationTerms, that.translationTerms) && + Objects.equals(translatedTerms, that.translatedTerms) && + Objects.equals(isA, that.isA) && + Objects.equals(classifies, that.classifies) && + Objects.equals(validValues, that.validValues) && + Objects.equals(validValuesFor, that.validValuesFor); + } + + @Override + public int hashCode() { + + return Objects.hash(super.hashCode(), examples, abbreviation, usage, anchor, assignedEntities, categories, + seeAlso, synonyms, antonyms, preferredTerms, preferredToTerms, replacementTerms, replacedBy, + translationTerms, translatedTerms, isA, classifies, validValues, validValuesFor); + } + + public enum Relation { + SEE_ALSO("__AtlasGlossaryRelatedTerm", "seeAlso"), + SYNONYMS("__AtlasGlossarySynonym", "synonyms"), + ANTONYMS("__AtlasGlossaryAntonym", "antonyms"), + PREFERRED_TERMS("__AtlasGlossaryPreferredTerm", "preferredTerms"), + PREFERRED_TO_TERMS("__AtlasGlossaryPreferredTerm", "preferredToTerms"), + REPLACEMENT_TERMS("__AtlasGlossaryReplacementTerm", "replacementTerms"), + REPLACED_BY("__AtlasGlossaryReplacementTerm", "replacedBy"), + TRANSLATION_TERMS("__AtlasGlossaryTranslation", "translationTerms"), + TRANSLATED_TERMS("__AtlasGlossaryTranslation", "translatedTerms"), + ISA("__AtlasGlossaryIsARelationship", "isA"), + CLASSIFIES("__AtlasGlossaryIsARelationship", "classifies"), + VALID_VALUES("__AtlasGlossaryValidValue", "validValues"), + VALID_VALUES_FOR("__AtlasGlossaryValidValue", "validValuesFor"), + ; + + private String relationName; + private String relationAttrName; + + Relation(final String relationName, final String relationAttrName) { + this.relationName = relationName; + this.relationAttrName = relationAttrName; + } + + public String getRelationName() { + return relationName; + } + + @JsonValue + public String getRelationAttrName() { + return relationAttrName; + } + } +}
http://git-wip-us.apache.org/repos/asf/atlas/blob/75415862/intg/src/main/java/org/apache/atlas/model/glossary/enums/AtlasTermAssignmentStatus.java ---------------------------------------------------------------------- diff --git a/intg/src/main/java/org/apache/atlas/model/glossary/enums/AtlasTermAssignmentStatus.java b/intg/src/main/java/org/apache/atlas/model/glossary/enums/AtlasTermAssignmentStatus.java new file mode 100644 index 0000000..0753d02 --- /dev/null +++ b/intg/src/main/java/org/apache/atlas/model/glossary/enums/AtlasTermAssignmentStatus.java @@ -0,0 +1,39 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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 + * <p> + * http://www.apache.org/licenses/LICENSE-2.0 + * <p> + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.atlas.model.glossary.enums; + +public enum AtlasTermAssignmentStatus { + DISCOVERED(0), + PROPOSED(1), + IMPORTED(2), + VALIDATED(3), + DEPRECATED(4), + OBSOLETE(5), + OTHER(6), + ; + + private int value; + + AtlasTermAssignmentStatus(final int value) { + this.value = value; + } + + public int getValue() { + return value; + } +} http://git-wip-us.apache.org/repos/asf/atlas/blob/75415862/intg/src/main/java/org/apache/atlas/model/glossary/enums/AtlasTermRelationshipStatus.java ---------------------------------------------------------------------- diff --git a/intg/src/main/java/org/apache/atlas/model/glossary/enums/AtlasTermRelationshipStatus.java b/intg/src/main/java/org/apache/atlas/model/glossary/enums/AtlasTermRelationshipStatus.java new file mode 100644 index 0000000..4c31c6a --- /dev/null +++ b/intg/src/main/java/org/apache/atlas/model/glossary/enums/AtlasTermRelationshipStatus.java @@ -0,0 +1,37 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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 + * <p> + * http://www.apache.org/licenses/LICENSE-2.0 + * <p> + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.atlas.model.glossary.enums; + +public enum AtlasTermRelationshipStatus { + DRAFT(0), + ACTIVE(1), + DEPRECATED(2), + OBSOLETE(3), + OTHER(99) + ; + + private int value; + + AtlasTermRelationshipStatus(final int value) { + this.value = value; + } + + public int getValue() { + return value; + } +} http://git-wip-us.apache.org/repos/asf/atlas/blob/75415862/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasGlossaryHeader.java ---------------------------------------------------------------------- diff --git a/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasGlossaryHeader.java b/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasGlossaryHeader.java new file mode 100644 index 0000000..bdf5f49 --- /dev/null +++ b/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasGlossaryHeader.java @@ -0,0 +1,79 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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 + * <p> + * http://www.apache.org/licenses/LICENSE-2.0 + * <p> + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.atlas.model.glossary.relations; + +import org.apache.atlas.model.annotation.AtlasJSON; + +import java.util.Objects; + +@AtlasJSON +public class AtlasGlossaryHeader { + private String glossaryGuid; + private String relationGuid; + private String displayText; + + public String getDisplayText() { + return displayText; + } + + public void setDisplayText(final String displayText) { + this.displayText = displayText; + } + + public String getGlossaryGuid() { + return glossaryGuid; + } + + public void setGlossaryGuid(final String glossaryGuid) { + this.glossaryGuid = glossaryGuid; + } + + @Override + public boolean equals(final Object o) { + if (this == o) return true; + if (!(o instanceof AtlasGlossaryHeader)) return false; + final AtlasGlossaryHeader that = (AtlasGlossaryHeader) o; + return Objects.equals(glossaryGuid, that.glossaryGuid) && + Objects.equals(relationGuid, that.relationGuid) && + Objects.equals(displayText, that.displayText); + } + + @Override + public int hashCode() { + + return Objects.hash(glossaryGuid, displayText); + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("AtlasGlossaryId{"); + sb.append("glossaryGuid='").append(glossaryGuid).append('\''); + sb.append(", relationGuid='").append(relationGuid).append('\''); + sb.append(", displayText='").append(displayText).append('\''); + sb.append('}'); + return sb.toString(); + } + + public String getRelationGuid() { + return relationGuid; + } + + public void setRelationGuid(final String relationGuid) { + this.relationGuid = relationGuid; + } +} http://git-wip-us.apache.org/repos/asf/atlas/blob/75415862/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasRelatedCategoryHeader.java ---------------------------------------------------------------------- diff --git a/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasRelatedCategoryHeader.java b/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasRelatedCategoryHeader.java new file mode 100644 index 0000000..aa7a6b1 --- /dev/null +++ b/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasRelatedCategoryHeader.java @@ -0,0 +1,93 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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 + * <p> + * http://www.apache.org/licenses/LICENSE-2.0 + * <p> + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.atlas.model.glossary.relations; + +import org.apache.atlas.model.annotation.AtlasJSON; + +import java.util.Objects; + +@AtlasJSON +public class AtlasRelatedCategoryHeader { + private String categoryGuid; + private String relationGuid; + private String displayText; + private String description; + + public AtlasRelatedCategoryHeader() { + } + + public String getCategoryGuid() { + return categoryGuid; + } + + public void setCategoryGuid(final String categoryGuid) { + this.categoryGuid = categoryGuid; + } + + public String getDescription() { + return description; + } + + public void setDescription(final String description) { + this.description = description; + } + + public String getDisplayText() { + return displayText; + } + + public void setDisplayText(final String displayText) { + this.displayText = displayText; + } + + @Override + public boolean equals(final Object o) { + if (this == o) return true; + if (!(o instanceof AtlasRelatedCategoryHeader)) return false; + final AtlasRelatedCategoryHeader that = (AtlasRelatedCategoryHeader) o; + return Objects.equals(categoryGuid, that.categoryGuid) && + Objects.equals(displayText, that.displayText) && + Objects.equals(description, that.description); + } + + @Override + public int hashCode() { + + return Objects.hash(categoryGuid, displayText, description); + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("AtlasRelatedCategoryId{"); + sb.append("categoryGuid='").append(categoryGuid).append('\''); + sb.append(", relationGuid='").append(relationGuid).append('\''); + sb.append(", displayText='").append(displayText).append('\''); + sb.append(", description='").append(description).append('\''); + sb.append('}'); + return sb.toString(); + } + + + public String getRelationGuid() { + return relationGuid; + } + + public void setRelationGuid(final String relationGuid) { + this.relationGuid = relationGuid; + } +} http://git-wip-us.apache.org/repos/asf/atlas/blob/75415862/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasRelatedTermHeader.java ---------------------------------------------------------------------- diff --git a/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasRelatedTermHeader.java b/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasRelatedTermHeader.java new file mode 100644 index 0000000..53781a1 --- /dev/null +++ b/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasRelatedTermHeader.java @@ -0,0 +1,139 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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 + * <p> + * http://www.apache.org/licenses/LICENSE-2.0 + * <p> + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.atlas.model.glossary.relations; + +import org.apache.atlas.model.annotation.AtlasJSON; +import org.apache.atlas.model.glossary.enums.AtlasTermRelationshipStatus; + +import java.util.Objects; + +@AtlasJSON +public class AtlasRelatedTermHeader { + private String termGuid; + private String relationGuid; + private String displayText; + private String description; + private String expression; + private String steward; + private String source; + + private AtlasTermRelationshipStatus status; + + public AtlasRelatedTermHeader() { + } + + public String getTermGuid() { + return termGuid; + } + + public void setTermGuid(final String termGuid) { + this.termGuid = termGuid; + } + + public String getDescription() { + return description; + } + + public void setDescription(final String description) { + this.description = description; + } + + public String getExpression() { + return expression; + } + + public void setExpression(final String expression) { + this.expression = expression; + } + + public String getSteward() { + return steward; + } + + public void setSteward(final String steward) { + this.steward = steward; + } + + public String getSource() { + return source; + } + + public void setSource(final String source) { + this.source = source; + } + + public AtlasTermRelationshipStatus getStatus() { + return status; + } + + public void setStatus(final AtlasTermRelationshipStatus status) { + this.status = status; + } + + @Override + public int hashCode() { + + return Objects.hash(termGuid, displayText, description, expression, steward, source, status); + } + + @Override + public boolean equals(final Object o) { + if (this == o) return true; + if (!(o instanceof AtlasRelatedTermHeader)) return false; + final AtlasRelatedTermHeader that = (AtlasRelatedTermHeader) o; + return Objects.equals(termGuid, that.termGuid) && + Objects.equals(relationGuid, that.relationGuid) && + Objects.equals(description, that.description) && + Objects.equals(displayText, that.displayText) && + Objects.equals(expression, that.expression) && + Objects.equals(steward, that.steward) && + Objects.equals(source, that.source) && + status == that.status; + } + + @Override + public String toString() { + final StringBuffer sb = new StringBuffer("AtlasRelatedTermId{"); + sb.append("termGuid='").append(termGuid).append('\''); + sb.append(", relationGuid='").append(relationGuid).append('\''); + sb.append(", description='").append(description).append('\''); + sb.append(", displayText='").append(displayText).append('\''); + sb.append(", expression='").append(expression).append('\''); + sb.append(", steward='").append(steward).append('\''); + sb.append(", source='").append(source).append('\''); + sb.append(", status=").append(status); + sb.append('}'); + return sb.toString(); + } + + public String getDisplayText() { + return displayText; + } + + public void setDisplayText(final String displayText) { + this.displayText = displayText; + } + + public String getRelationGuid() { + return relationGuid; + } + + public void setRelationGuid(final String relationGuid) { + this.relationGuid = relationGuid; + } +} http://git-wip-us.apache.org/repos/asf/atlas/blob/75415862/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasTermAssignmentHeader.java ---------------------------------------------------------------------- diff --git a/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasTermAssignmentHeader.java b/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasTermAssignmentHeader.java new file mode 100644 index 0000000..b4682ed --- /dev/null +++ b/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasTermAssignmentHeader.java @@ -0,0 +1,162 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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 + * <p> + * http://www.apache.org/licenses/LICENSE-2.0 + * <p> + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.atlas.model.glossary.relations; + +import org.apache.atlas.model.annotation.AtlasJSON; +import org.apache.atlas.model.glossary.enums.AtlasTermAssignmentStatus; + +import java.util.Objects; + +@AtlasJSON +public class AtlasTermAssignmentHeader { + private String termGuid; + private String relationGuid; + private String description; + private String displayText; + private String expression; + private String createdBy; + private String steward; + private String source; + private int confidence; + + private AtlasTermAssignmentStatus status; + + public AtlasTermAssignmentHeader() { + } + + public String getTermGuid() { + return termGuid; + } + + public void setTermGuid(final String termGuid) { + this.termGuid = termGuid; + } + + public String getDescription() { + return description; + } + + public void setDescription(final String description) { + this.description = description; + } + + public String getExpression() { + return expression; + } + + public void setExpression(final String expression) { + this.expression = expression; + } + + public String getCreatedBy() { + return createdBy; + } + + public void setCreatedBy(final String createdBy) { + this.createdBy = createdBy; + } + + public String getSteward() { + return steward; + } + + public void setSteward(final String steward) { + this.steward = steward; + } + + public String getSource() { + return source; + } + + public void setSource(final String source) { + this.source = source; + } + + public int getConfidence() { + return confidence; + } + + public void setConfidence(final int confidence) { + this.confidence = confidence; + } + + public AtlasTermAssignmentStatus getStatus() { + return status; + } + + public void setStatus(final AtlasTermAssignmentStatus status) { + this.status = status; + } + + public String getDisplayText() { + return displayText; + } + + public void setDisplayText(final String displayText) { + this.displayText = displayText; + } + + @Override + public int hashCode() { + + return Objects.hash(termGuid, description, displayText, expression, createdBy, steward, source, confidence, status); + } + + @Override + public boolean equals(final Object o) { + if (this == o) return true; + if (!(o instanceof AtlasTermAssignmentHeader)) return false; + final AtlasTermAssignmentHeader that = (AtlasTermAssignmentHeader) o; + return confidence == that.confidence && + Objects.equals(termGuid, that.termGuid) && + Objects.equals(relationGuid, that.relationGuid) && + Objects.equals(description, that.description) && + Objects.equals(displayText, that.displayText) && + Objects.equals(expression, that.expression) && + Objects.equals(createdBy, that.createdBy) && + Objects.equals(steward, that.steward) && + Objects.equals(source, that.source) && + status == that.status; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("AtlasTermAssignmentId{"); + sb.append("termGuid='").append(termGuid).append('\''); + sb.append(", relationGuid='").append(relationGuid).append('\''); + sb.append(", description='").append(description).append('\''); + sb.append(", displayText='").append(displayText).append('\''); + sb.append(", expression='").append(expression).append('\''); + sb.append(", createdBy='").append(createdBy).append('\''); + sb.append(", steward='").append(steward).append('\''); + sb.append(", source='").append(source).append('\''); + sb.append(", confidence=").append(confidence); + sb.append(", status=").append(status); + sb.append('}'); + return sb.toString(); + } + + + public String getRelationGuid() { + return relationGuid; + } + + public void setRelationGuid(final String relationGuid) { + this.relationGuid = relationGuid; + } +} http://git-wip-us.apache.org/repos/asf/atlas/blob/75415862/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasTermCategorizationHeader.java ---------------------------------------------------------------------- diff --git a/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasTermCategorizationHeader.java b/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasTermCategorizationHeader.java new file mode 100644 index 0000000..28397d9 --- /dev/null +++ b/intg/src/main/java/org/apache/atlas/model/glossary/relations/AtlasTermCategorizationHeader.java @@ -0,0 +1,107 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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 + * <p> + * http://www.apache.org/licenses/LICENSE-2.0 + * <p> + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.atlas.model.glossary.relations; + +import org.apache.atlas.model.annotation.AtlasJSON; +import org.apache.atlas.model.glossary.enums.AtlasTermRelationshipStatus; + +import java.util.Objects; + +@AtlasJSON +public class AtlasTermCategorizationHeader { + private String categoryGuid; + private String relationGuid; + private String description; + private String displayText; + + private AtlasTermRelationshipStatus status; + + public AtlasTermCategorizationHeader() { + } + + public String getCategoryGuid() { + return categoryGuid; + } + + public void setCategoryGuid(final String categoryGuid) { + this.categoryGuid = categoryGuid; + } + + public String getDescription() { + return description; + } + + public void setDescription(final String description) { + this.description = description; + } + + public AtlasTermRelationshipStatus getStatus() { + return status; + } + + public void setStatus(final AtlasTermRelationshipStatus status) { + this.status = status; + } + + public String getDisplayText() { + return displayText; + } + + public void setDisplayText(final String displayText) { + this.displayText = displayText; + } + + @Override + public boolean equals(final Object o) { + if (this == o) return true; + if (!(o instanceof AtlasTermCategorizationHeader)) return false; + final AtlasTermCategorizationHeader that = (AtlasTermCategorizationHeader) o; + return Objects.equals(categoryGuid, that.categoryGuid) && + Objects.equals(relationGuid, that.relationGuid) && + Objects.equals(description, that.description) && + Objects.equals(displayText, that.displayText) && + status == that.status; + } + + @Override + public int hashCode() { + + return Objects.hash(categoryGuid, relationGuid, description, displayText, status); + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("AtlasTermCategorizationId{"); + sb.append("categoryGuid='").append(categoryGuid).append('\''); + sb.append(", relationGuid='").append(relationGuid).append('\''); + sb.append(", description='").append(description).append('\''); + sb.append(", displayText='").append(displayText).append('\''); + sb.append(", status=").append(status); + sb.append('}'); + return sb.toString(); + } + + + public String getRelationGuid() { + return relationGuid; + } + + public void setRelationGuid(final String relationGuid) { + this.relationGuid = relationGuid; + } +} http://git-wip-us.apache.org/repos/asf/atlas/blob/75415862/intg/src/main/java/org/apache/atlas/model/instance/AtlasEntity.java ---------------------------------------------------------------------- diff --git a/intg/src/main/java/org/apache/atlas/model/instance/AtlasEntity.java b/intg/src/main/java/org/apache/atlas/model/instance/AtlasEntity.java index 0e6f9c7..e6a7f19 100644 --- a/intg/src/main/java/org/apache/atlas/model/instance/AtlasEntity.java +++ b/intg/src/main/java/org/apache/atlas/model/instance/AtlasEntity.java @@ -22,9 +22,9 @@ import com.fasterxml.jackson.annotation.JsonAutoDetect; import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import com.fasterxml.jackson.databind.annotation.JsonSerialize; - import org.apache.atlas.model.PList; import org.apache.atlas.model.SearchFilter.SortType; +import org.apache.atlas.model.glossary.relations.AtlasTermAssignmentHeader; import org.apache.atlas.model.typedef.AtlasBaseTypeDef; import org.apache.atlas.model.typedef.AtlasEntityDef; import org.apache.commons.collections.CollectionUtils; @@ -80,9 +80,10 @@ public class AtlasEntity extends AtlasStruct implements Serializable { private Date updateTime = null; private Long version = 0L; - private Map<String, Object> relationshipAttributes; - private List<AtlasClassification> classifications; - private List<AtlasClassification> propagationDisabledClassifications; + private Map<String, Object> relationshipAttributes; + private List<AtlasClassification> classifications; + private List<AtlasClassification> propagationDisabledClassifications; + private List<AtlasTermAssignmentHeader> meanings; @JsonIgnore private static AtomicLong s_nextId = new AtomicLong(System.nanoTime()); @@ -280,6 +281,24 @@ public class AtlasEntity extends AtlasStruct implements Serializable { this.classifications = c; } + public List<AtlasTermAssignmentHeader> getMeanings() { + return meanings; + } + + public void setMeanings(final List<AtlasTermAssignmentHeader> meanings) { + this.meanings = meanings; + } + + public void addMeaning(AtlasTermAssignmentHeader meaning) { + List<AtlasTermAssignmentHeader> meanings = this.meanings; + + if (meanings == null) { + meanings = new ArrayList<>(); + } + meanings.add(meaning); + setMeanings(meanings); + } + private void init() { setGuid(nextInternalId()); setStatus(null); @@ -289,6 +308,7 @@ public class AtlasEntity extends AtlasStruct implements Serializable { setUpdateTime(null); setClassifications(null); setPropagationDisabledClassifications(null); + setMeanings(null); } private static String nextInternalId() { @@ -319,6 +339,9 @@ public class AtlasEntity extends AtlasStruct implements Serializable { sb.append(", propagationDisabledClassifications=["); AtlasBaseTypeDef.dumpObjects(propagationDisabledClassifications, sb); sb.append(']'); + sb.append(", meanings=["); + AtlasBaseTypeDef.dumpObjects(meanings, sb); + sb.append(']'); sb.append('}'); return sb; http://git-wip-us.apache.org/repos/asf/atlas/blob/75415862/intg/src/main/java/org/apache/atlas/model/instance/AtlasEntityHeader.java ---------------------------------------------------------------------- diff --git a/intg/src/main/java/org/apache/atlas/model/instance/AtlasEntityHeader.java b/intg/src/main/java/org/apache/atlas/model/instance/AtlasEntityHeader.java index 9db9200..6ad830a 100644 --- a/intg/src/main/java/org/apache/atlas/model/instance/AtlasEntityHeader.java +++ b/intg/src/main/java/org/apache/atlas/model/instance/AtlasEntityHeader.java @@ -6,9 +6,9 @@ * to you 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 - * + * <p> + * http://www.apache.org/licenses/LICENSE-2.0 + * <p> * 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. @@ -21,24 +21,23 @@ package org.apache.atlas.model.instance; import com.fasterxml.jackson.annotation.JsonAutoDetect; import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import com.fasterxml.jackson.databind.annotation.JsonSerialize; +import org.apache.atlas.model.PList; +import org.apache.atlas.model.SearchFilter.SortType; +import org.apache.atlas.model.glossary.relations.AtlasTermAssignmentHeader; +import org.apache.atlas.model.typedef.AtlasBaseTypeDef; +import org.apache.atlas.model.typedef.AtlasEntityDef; +import org.apache.commons.collections.CollectionUtils; +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlSeeAlso; import java.io.Serializable; import java.util.ArrayList; import java.util.List; import java.util.Map; import java.util.Objects; -import javax.xml.bind.annotation.XmlAccessType; -import javax.xml.bind.annotation.XmlAccessorType; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlSeeAlso; - -import org.apache.atlas.model.PList; -import org.apache.atlas.model.SearchFilter.SortType; -import org.apache.atlas.model.typedef.AtlasBaseTypeDef; -import org.apache.atlas.model.typedef.AtlasEntityDef; -import org.apache.commons.collections.CollectionUtils; - import static com.fasterxml.jackson.annotation.JsonAutoDetect.Visibility.NONE; import static com.fasterxml.jackson.annotation.JsonAutoDetect.Visibility.PUBLIC_ONLY; @@ -46,19 +45,21 @@ import static com.fasterxml.jackson.annotation.JsonAutoDetect.Visibility.PUBLIC_ /** * An instance of an entity - like hive_table, hive_database. */ -@JsonAutoDetect(getterVisibility=PUBLIC_ONLY, setterVisibility=PUBLIC_ONLY, fieldVisibility=NONE) -@JsonSerialize(include=JsonSerialize.Inclusion.NON_NULL) -@JsonIgnoreProperties(ignoreUnknown=true) +@JsonAutoDetect(getterVisibility = PUBLIC_ONLY, setterVisibility = PUBLIC_ONLY, fieldVisibility = NONE) +@JsonSerialize(include = JsonSerialize.Inclusion.NON_NULL) +@JsonIgnoreProperties(ignoreUnknown = true) @XmlRootElement @XmlAccessorType(XmlAccessType.PROPERTY) public class AtlasEntityHeader extends AtlasStruct implements Serializable { private static final long serialVersionUID = 1L; - private String guid = null; - private AtlasEntity.Status status = AtlasEntity.Status.ACTIVE; - private String displayText = null; - private List<String> classificationNames = null; - private List<AtlasClassification> classifications = null; + private String guid = null; + private AtlasEntity.Status status = AtlasEntity.Status.ACTIVE; + private String displayText = null; + private List<String> classificationNames = null; + private List<AtlasClassification> classifications = null; + private List<String> meaningNames = null; + private List<AtlasTermAssignmentHeader> meanings = null; public AtlasEntityHeader() { this(null, null); @@ -80,7 +81,7 @@ public class AtlasEntityHeader extends AtlasStruct implements Serializable { } - public AtlasEntityHeader(String typeName, String guid, Map<String, Object> attributes) { + public AtlasEntityHeader(String typeName, String guid, Map<String, Object> attributes) { super(typeName, attributes); setGuid(guid); setClassificationNames(null); @@ -100,7 +101,7 @@ public class AtlasEntityHeader extends AtlasStruct implements Serializable { } } - public AtlasEntityHeader(AtlasEntity entity){ + public AtlasEntityHeader(AtlasEntity entity) { super(entity.getTypeName(), entity.getAttributes()); setGuid(entity.getGuid()); setClassifications(entity.getClassifications()); @@ -138,7 +139,7 @@ public class AtlasEntityHeader extends AtlasStruct implements Serializable { this.displayText = displayText; } - public List<String> getClassificationNames(){ + public List<String> getClassificationNames() { return classificationNames; } @@ -146,9 +147,13 @@ public class AtlasEntityHeader extends AtlasStruct implements Serializable { this.classificationNames = classificationNames; } - public List<AtlasClassification> getClassifications() { return classifications; } + public List<AtlasClassification> getClassifications() { + return classifications; + } - public void setClassifications(List<AtlasClassification> classifications) { this.classifications = classifications; } + public void setClassifications(List<AtlasClassification> classifications) { + this.classifications = classifications; + } @Override public StringBuilder toString(StringBuilder sb) { @@ -179,15 +184,17 @@ public class AtlasEntityHeader extends AtlasStruct implements Serializable { if (!super.equals(o)) return false; AtlasEntityHeader that = (AtlasEntityHeader) o; return Objects.equals(guid, that.guid) && - status == that.status && - Objects.equals(displayText, that.displayText) && - Objects.equals(classificationNames, that.classificationNames) && - Objects.equals(classifications, that.classifications); + status == that.status && + Objects.equals(displayText, that.displayText) && + Objects.equals(classificationNames, that.classificationNames) && + Objects.equals(meaningNames, that.classificationNames) && + Objects.equals(classifications, that.classifications) && + Objects.equals(meanings, that.meanings); } @Override public int hashCode() { - return Objects.hash(super.hashCode(), guid, status, displayText, classificationNames, classifications); + return Objects.hash(super.hashCode(), guid, status, displayText, classificationNames, classifications, meaningNames, meanings); } @Override @@ -195,12 +202,28 @@ public class AtlasEntityHeader extends AtlasStruct implements Serializable { return toString(new StringBuilder()).toString(); } + public List<String> getMeaningNames() { + return meaningNames; + } + + public void setMeaningNames(final List<String> meaningNames) { + this.meaningNames = meaningNames; + } + + public List<AtlasTermAssignmentHeader> getMeanings() { + return meanings; + } + + public void setMeanings(final List<AtlasTermAssignmentHeader> meanings) { + this.meanings = meanings; + } + /** * REST serialization friendly list. */ - @JsonAutoDetect(getterVisibility=PUBLIC_ONLY, setterVisibility=PUBLIC_ONLY, fieldVisibility=NONE) - @JsonSerialize(include=JsonSerialize.Inclusion.NON_NULL) - @JsonIgnoreProperties(ignoreUnknown=true) + @JsonAutoDetect(getterVisibility = PUBLIC_ONLY, setterVisibility = PUBLIC_ONLY, fieldVisibility = NONE) + @JsonSerialize(include = JsonSerialize.Inclusion.NON_NULL) + @JsonIgnoreProperties(ignoreUnknown = true) @XmlRootElement @XmlAccessorType(XmlAccessType.PROPERTY) @XmlSeeAlso(AtlasEntity.class) @@ -216,7 +239,7 @@ public class AtlasEntityHeader extends AtlasStruct implements Serializable { } public AtlasEntityHeaders(List list, long startIndex, int pageSize, long totalCount, - SortType sortType, String sortBy) { + SortType sortType, String sortBy) { super(list, startIndex, pageSize, totalCount, sortType, sortBy); } } http://git-wip-us.apache.org/repos/asf/atlas/blob/75415862/intg/src/main/java/org/apache/atlas/model/instance/AtlasRelationship.java ---------------------------------------------------------------------- diff --git a/intg/src/main/java/org/apache/atlas/model/instance/AtlasRelationship.java b/intg/src/main/java/org/apache/atlas/model/instance/AtlasRelationship.java index 576847f..c133e39 100644 --- a/intg/src/main/java/org/apache/atlas/model/instance/AtlasRelationship.java +++ b/intg/src/main/java/org/apache/atlas/model/instance/AtlasRelationship.java @@ -22,17 +22,14 @@ import com.fasterxml.jackson.annotation.JsonAutoDetect; import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import com.fasterxml.jackson.databind.annotation.JsonSerialize; - import org.apache.atlas.model.typedef.AtlasRelationshipDef; import org.apache.atlas.model.typedef.AtlasRelationshipDef.PropagateTags; -import org.apache.atlas.type.AtlasBuiltInTypes; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlRootElement; import java.io.Serializable; import java.util.Date; -import java.util.HashMap; import java.util.Map; import java.util.Objects; import java.util.concurrent.atomic.AtomicLong; http://git-wip-us.apache.org/repos/asf/atlas/blob/75415862/intg/src/main/java/org/apache/atlas/type/AtlasRelationshipType.java ---------------------------------------------------------------------- diff --git a/intg/src/main/java/org/apache/atlas/type/AtlasRelationshipType.java b/intg/src/main/java/org/apache/atlas/type/AtlasRelationshipType.java index 61168f6..5abae95 100644 --- a/intg/src/main/java/org/apache/atlas/type/AtlasRelationshipType.java +++ b/intg/src/main/java/org/apache/atlas/type/AtlasRelationshipType.java @@ -20,9 +20,7 @@ package org.apache.atlas.type; import org.apache.atlas.AtlasErrorCode; import org.apache.atlas.exception.AtlasBaseException; -import org.apache.atlas.model.instance.AtlasObjectId; import org.apache.atlas.model.instance.AtlasRelationship; -import org.apache.atlas.model.instance.AtlasStruct; import org.apache.atlas.model.typedef.AtlasBaseTypeDef; import org.apache.atlas.model.typedef.AtlasRelationshipDef; import org.apache.atlas.model.typedef.AtlasRelationshipDef.RelationshipCategory;