Esempio n. 1
0
 @Override
 public List<metadslx.core.MetaProperty> MetaClass_getAllProperties(
     metadslx.core.MetaClass _this) {
   ArrayList<MetaProperty> result = new ArrayList<>();
   for (MetaProperty prop : _this.getProperties()) {
     result.add(prop);
   }
   for (MetaClass cls : _this.getAllSuperClasses()) {
     for (MetaProperty prop : cls.getProperties()) {
       result.add(prop);
     }
   }
   return result;
 }
Esempio n. 2
0
 @Override
 public List<metadslx.core.MetaOperation> MetaClass_getAllOperations(
     metadslx.core.MetaClass _this) {
   ArrayList<MetaOperation> result = new ArrayList<>();
   for (MetaOperation oper : _this.getOperations()) {
     result.add(oper);
   }
   for (MetaClass cls : _this.getAllSuperClasses()) {
     for (MetaOperation oper : cls.getOperations()) {
       result.add(oper);
     }
   }
   return result;
 }
Esempio n. 3
0
 @Override
 public List<metadslx.core.MetaClass> MetaClass_getAllSuperClasses(metadslx.core.MetaClass _this) {
   ArrayList<MetaClass> result = new ArrayList<>();
   for (MetaClass sup : _this.getSuperClasses()) {
     Collection<MetaClass> allSupers = sup.getAllSuperClasses();
     if (!result.contains(sup)) {
       result.add(sup);
     }
     for (MetaClass supSup : allSupers) {
       if (!result.contains(supSup)) {
         result.add(supSup);
       }
     }
   }
   return result;
 }
Esempio n. 4
0
 @Override
 public List<metadslx.core.MetaOperation> MetaClass_getAllImplementedOperations(
     metadslx.core.MetaClass _this) {
   List<MetaOperation> ops = _this.getAllOperations();
   int i = ops.size() - 1;
   while (i >= 0) {
     String name = ops.get(i).getName();
     MetaOperation op = null;
     for (MetaOperation o : ops) {
       if (name.equals(o.getName())) {
         op = o;
         break;
       }
     }
     if (op != ops.get(i)) {
       ops.remove(i);
     }
     --i;
   }
   return ops;
 }
Esempio n. 5
0
 @Override
 public List<metadslx.core.MetaProperty> MetaClass_getAllImplementedProperties(
     metadslx.core.MetaClass _this) {
   List<MetaProperty> props = _this.getAllProperties();
   int i = props.size() - 1;
   while (i >= 0) {
     String name = props.get(i).getName();
     MetaProperty prop = null;
     for (MetaProperty p : props) {
       if (name.equals(p.getName())) {
         prop = p;
         break;
       }
     }
     if (prop != props.get(i)) {
       props.remove(i);
     }
     --i;
   }
   return props;
 }