class Const {

  public static String trimToType( String string, int trimType ) {
    switch ( trimType ) {
      case ValueMetaInterface.TRIM_TYPE_BOTH:
        return trim( string );
      case ValueMetaInterface.TRIM_TYPE_LEFT:
        return ltrim( string );
      case ValueMetaInterface.TRIM_TYPE_RIGHT:
        return rtrim( string );
      case ValueMetaInterface.TRIM_TYPE_NONE:
      default:
        return string;
    }
  }

}