Example #1
0
  public void vizAllowObject(Stella_Object renamed_Object) {
    {
      VizInfo self = this;

      {
        HashSet allowedobjects = self.allowedObjects;

        if (allowedobjects == null) {
          allowedobjects = HashSet.newHashSet();
          self.allowedObjects = allowedobjects;
        }
        allowedobjects.insert(renamed_Object);
      }
    }
  }
Example #2
0
  public static VizInfo newVizInfo() {
    {
      VizInfo self = null;

      self = new VizInfo();
      self.fontSize = OntosaurusUtil.$VIZ_FONT_SIZE$;
      self.relationStyle = OntosaurusUtil.$VIZ_RELATION_STYLE$;
      self.relationColor = OntosaurusUtil.$VIZ_RELATION_COLOR$;
      self.nodeColor = OntosaurusUtil.$VIZ_NODE_COLOR$;
      self.addTopP = OntosaurusUtil.$VIZ_ADD_TOPp$;
      self.showRulesP = OntosaurusUtil.$VIZ_SHOW_RULESp$;
      self.showAttributesP = OntosaurusUtil.$VIZ_SHOW_ATTRIBUTESp$;
      self.showRelationsP = OntosaurusUtil.$VIZ_SHOW_RELATIONSp$;
      self.allowedObjects = null;
      self.stream = null;
      return (self);
    }
  }
Example #3
0
  public static Stella_Object accessVizInfoSlotValue(
      VizInfo self, Symbol slotname, Stella_Object value, boolean setvalueP) {
    if (slotname == OntosaurusUtil.SYM_STELLA_STREAM) {
      if (setvalueP) {
        self.stream = ((OutputStream) (value));
      } else {
        value = self.stream;
      }
    } else if (slotname == OntosaurusUtil.SYM_ONTOSAURUS_ALLOWED_OBJECTS) {
      if (setvalueP) {
        self.allowedObjects = ((HashSet) (value));
      } else {
        value = self.allowedObjects;
      }
    } else if (slotname == OntosaurusUtil.SYM_ONTOSAURUS_SHOW_RELATIONSp) {
      if (setvalueP) {
        self.showRelationsP =
            BooleanWrapper.coerceWrappedBooleanToBoolean(((BooleanWrapper) (value)));
      } else {
        value = (self.showRelationsP ? Stella.TRUE_WRAPPER : Stella.FALSE_WRAPPER);
      }
    } else if (slotname == OntosaurusUtil.SYM_ONTOSAURUS_SHOW_ATTRIBUTESp) {
      if (setvalueP) {
        self.showAttributesP =
            BooleanWrapper.coerceWrappedBooleanToBoolean(((BooleanWrapper) (value)));
      } else {
        value = (self.showAttributesP ? Stella.TRUE_WRAPPER : Stella.FALSE_WRAPPER);
      }
    } else if (slotname == OntosaurusUtil.SYM_ONTOSAURUS_SHOW_RULESp) {
      if (setvalueP) {
        self.showRulesP = BooleanWrapper.coerceWrappedBooleanToBoolean(((BooleanWrapper) (value)));
      } else {
        value = (self.showRulesP ? Stella.TRUE_WRAPPER : Stella.FALSE_WRAPPER);
      }
    } else if (slotname == OntosaurusUtil.SYM_ONTOSAURUS_ADD_TOPp) {
      if (setvalueP) {
        self.addTopP = BooleanWrapper.coerceWrappedBooleanToBoolean(((BooleanWrapper) (value)));
      } else {
        value = (self.addTopP ? Stella.TRUE_WRAPPER : Stella.FALSE_WRAPPER);
      }
    } else if (slotname == OntosaurusUtil.SYM_ONTOSAURUS_NODE_COLOR) {
      if (setvalueP) {
        self.nodeColor = ((StringWrapper) (value)).wrapperValue;
      } else {
        value = StringWrapper.wrapString(self.nodeColor);
      }
    } else if (slotname == OntosaurusUtil.SYM_ONTOSAURUS_RELATION_COLOR) {
      if (setvalueP) {
        self.relationColor = ((StringWrapper) (value)).wrapperValue;
      } else {
        value = StringWrapper.wrapString(self.relationColor);
      }
    } else if (slotname == OntosaurusUtil.SYM_ONTOSAURUS_RELATION_STYLE) {
      if (setvalueP) {
        self.relationStyle = ((StringWrapper) (value)).wrapperValue;
      } else {
        value = StringWrapper.wrapString(self.relationStyle);
      }
    } else if (slotname == OntosaurusUtil.SYM_ONTOSAURUS_FONT_SIZE) {
      if (setvalueP) {
        self.fontSize = ((IntegerWrapper) (value)).wrapperValue;
      } else {
        value = IntegerWrapper.wrapInteger(self.fontSize);
      }
    } else {
      {
        OutputStringStream stream000 = OutputStringStream.newOutputStringStream();

        stream000.nativeStream.print("`" + slotname + "' is not a valid case option");
        throw ((StellaException)
            (StellaException.newStellaException(stream000.theStringReader()).fillInStackTrace()));
      }
    }
    return (value);
  }