コード例 #1
0
  /**
   * Updates values in report parameter by given ROM data set parameter.
   *
   * @param reportParam the report parameter
   * @param dataSetParam the data set parameter
   * @param updateDefaultValue the flag which indicates if the default value need to be forced
   *     updated.
   * @throws SemanticException
   */
  protected void updateLinkedReportParameterFromROMParameter(
      AbstractScalarParameterHandle reportParam,
      OdaDataSetParameterHandle dataSetParam,
      boolean updateDefaultValue)
      throws SemanticException {
    assert reportParam != null;

    if (dataSetParam == null) return;

    // should not convert report parameter name here.

    Object defaultValue =
        dataSetParam.getExpressionProperty(OdaDataSetParameter.DEFAULT_VALUE_MEMBER).getValue();
    String paramName = dataSetParam.getParamName();

    if (StringUtil.isBlank(paramName)) {
      dataSetParam.setParamName(reportParam.getName());
    }
    if (updateDefaultValue) setROMDefaultValue(reportParam, defaultValue);
  }
コード例 #2
0
 public static String getLabelColumnName(AbstractScalarParameterHandle parameter) {
   if (parameter.getLabelExpr() == null) {
     return null;
   }
   return LABEL_PREFIX + "_" + parameter.getName();
 }
コード例 #3
0
 public static String getValueColumnName(AbstractScalarParameterHandle parameter) {
   return VALUE_PREFIX + "_" + parameter.getName();
 }