class ValueMetaFactory {

  public static IValueMeta createValueMeta( String name, int type, int length, int precision ) throws HopPluginException {
    IPlugin stringPlugin = pluginRegistry.getPlugin( ValueMetaPluginType.class, String.valueOf( type ) );
    if ( stringPlugin == null ) {
      throw new HopPluginException( "Unable to locate value meta plugin of type (id) " + type );
    }
    IValueMeta valueMeta = pluginRegistry.loadClass( stringPlugin, IValueMeta.class );
    valueMeta.setName( name );
    valueMeta.setLength( length, precision );
    return valueMeta;
  }

  private  ValueMetaFactory();

}