You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@atlas.apache.org by ltf <lt...@163.com> on 2015/09/10 10:25:11 UTC
[Atlas] A source code question
Hello,
When reading the source code of trunk, I think the following code may be a issue, or is intended ???
file : org/apache/atlas/typesystem/types/TypeSystem.java
for (StructTypeDefinition structDef : structDefs) {
constructStructureType(structDef);
typeCategoriesToTypeNamesMap.put(DataTypes.TypeCategory.CLASS, structDef.typeName); //should be DataTypes.TypeCategory.STRUCT ???
}
for (TraitType traitType : traitTypes) {
constructHierarchicalType(TraitType.class, traitNameToDefMap.get(traitType.getName()));
typeCategoriesToTypeNamesMap.put(DataTypes.TypeCategory.TRAIT, traitType.getName());
}
for (ClassType classType : classTypes) {
constructHierarchicalType(ClassType.class, classNameToDefMap.get(classType.getName()));
typeCategoriesToTypeNamesMap.put(DataTypes.TypeCategory.CLASS, classType.getName());
}
Best, liutongfeng
Re: [Atlas] A source code question
Posted by Shwetha Shivalingamurthy <ss...@hortonworks.com>.
Should be struct. Can you file a bug please? Thanks
Regards,
Shwetha
On 10/09/15 1:55 pm, "ltf" <lt...@163.com> wrote:
>Hello,
>When reading the source code of trunk, I think the following code may be
>a issue, or is intended ???
>
>
>file : org/apache/atlas/typesystem/types/TypeSystem.java
>for (StructTypeDefinition structDef : structDefs) {
> constructStructureType(structDef);
>typeCategoriesToTypeNamesMap.put(DataTypes.TypeCategory.CLASS,
>structDef.typeName); //should be DataTypes.TypeCategory.STRUCT ???
>}
>
>for (TraitType traitType : traitTypes) {
> constructHierarchicalType(TraitType.class,
>traitNameToDefMap.get(traitType.getName()));
>typeCategoriesToTypeNamesMap.put(DataTypes.TypeCategory.TRAIT,
>traitType.getName());
>}
>
>for (ClassType classType : classTypes) {
> constructHierarchicalType(ClassType.class,
>classNameToDefMap.get(classType.getName()));
>typeCategoriesToTypeNamesMap.put(DataTypes.TypeCategory.CLASS,
>classType.getName());
>}
>
>
>Best, liutongfeng