1 23 24 package org.objectweb.jorm.metainfo.lib; 25 26 import org.objectweb.jorm.metainfo.api.TypedElement; 27 import org.objectweb.jorm.metainfo.api.MetaObject; 28 import org.objectweb.jorm.type.api.PType; 29 30 33 public class BasicTypedElement extends BasicMetaObject 34 implements TypedElement, Comparable { 35 36 39 private String name; 40 41 44 private PType type; 45 46 47 54 public BasicTypedElement(String name, PType pType, MetaObject parent) { 55 super(parent); 56 this.name = name; 57 this.type = pType; 58 } 59 60 public int compareTo(Object o) { 61 return name.compareTo(((TypedElement) o).getName()); 62 } 63 64 69 public String getName() { 70 return name; 71 } 72 73 78 public PType getType() { 79 return type; 80 } 81 82 } | Popular Tags |