コード例 #1
0
  @Override
  public void setPropertyValue(Object id, Object value) {
    JRDesignComponentElement jrElement = (JRDesignComponentElement) getValue();
    UPCAComponent jrList = (UPCAComponent) jrElement.getComponent();

    if (id.equals(UPCAComponent.PROPERTY_CHECKSUM_MODE))
      jrList.setChecksumMode(ChecksumMode.getChecksumMode4Pos((Integer) value));
    else super.setPropertyValue(id, value);
  }
コード例 #2
0
  @Override
  public Object getPropertyValue(Object id) {
    JRDesignComponentElement jrElement = (JRDesignComponentElement) getValue();
    UPCAComponent jrList = (UPCAComponent) jrElement.getComponent();

    if (id.equals(UPCAComponent.PROPERTY_CHECKSUM_MODE))
      return ChecksumMode.getPos4ChecksumMode(jrList.getChecksumMode());
    return super.getPropertyValue(id);
  }
コード例 #3
0
  /**
   * Creates the property descriptors.
   *
   * @param desc the desc
   */
  @Override
  public void createPropertyDescriptors(
      List<IPropertyDescriptor> desc, Map<String, Object> defaultsMap) {
    super.createPropertyDescriptors(desc, defaultsMap);

    JSSComboPropertyDescriptor checksumModeD =
        new JSSComboPropertyDescriptor(
            UPCAComponent.PROPERTY_CHECKSUM_MODE,
            Messages.common_checksum_mode,
            ChecksumMode.getItems());
    checksumModeD.setDescription(Messages.MUPCA_checksum_mode_description);
    desc.add(checksumModeD);

    checksumModeD.setCategory(Messages.MUPCA_properties_category);
  }