Exemplo n.º 1
0
  /**
   * Insert the method's description here. Creation date: (28.1.2001 13:12:23)
   *
   * @param field com.cosylab.vdct.vdb.VDBFieldData
   */
  public void fieldValueChanged(VDBFieldData field) {
    Record visualRecord = (Record) Group.getRoot().findObject(getName(), true);
    if (visualRecord == null) {
      // com.cosylab.vdct.Console.getInstance().println("o) Internal error: no visual representation
      // of record "+getName()+" found.");
      return;
    }

    com.cosylab.vdct.inspector.InspectorManager.getInstance().updateProperty(visualRecord, field);
    visualRecord.fieldChanged(field);
  }
Exemplo n.º 2
0
  /**
   * Insert the method's description here. Creation date: (9.12.2000 18:13:17)
   *
   * @param newComment java.lang.String
   */
  public void setComment(java.lang.String newComment) {
    comment = newComment;

    Inspectable visualObj = (Inspectable) Group.getRoot().findObject(getName(), true);
    if (visualObj == null) {
      // com.cosylab.vdct.Console.getInstance().println("o) Internal error: no visual representation
      // of record "+getName()+" found.");
      return;
    }

    com.cosylab.vdct.inspector.InspectorManager.getInstance().updateCommentProperty(visualObj);
  }
Exemplo n.º 3
0
    public void actionPerformed(ActionEvent e) {
      String recordName = e.getActionCommand();
      Console.getInstance().println("CosyBeansPlugin action: " + recordName);

      // TBD: special case for "Show all..." -> should have other handler, etc...

      Group root = Group.getRoot();
      if (root == null) {
        Console.getInstance().println("CosyBeansPlugin: failed to find database.");
        return;
      }

      // search for record object
      Record record = (Record) root.findObject(recordName, true);
      if (record == null) {
        Console.getInstance()
            .println("CosyBeansPlugin: failed to find '" + recordName + "' record.");
        return;
      }

      // search for record definition object
      DBDRecordData recordDefinition =
          DataProvider.getInstance().getDbdDB().getDBDRecordData(record.getRecordData().getType());
      if (recordDefinition == null) {
        Console.getInstance()
            .println(
                "CosyBeansPlugin: failed to find '"
                    + record.getRecordData().getType()
                    + "' record definition.");
        return;
      }

      // find VAL field
      DBDFieldData fieldData = recordDefinition.getDBDFieldData("VAL");
      if (fieldData == null) {
        Console.getInstance()
            .println(
                "CosyBeansPlugin: failed to find VAL field in '"
                    + record.getRecordData().getType()
                    + "' record definition.");
        return;
      }

      // String channelType = getFieldType(fieldData.getField_type());

      // call abeans

    }