code: @Override
      public ResourceSchema getSchema(final String location, final Job job) throws IOException
      {
          final List<Schema.FieldSchema> schemaList = new ArrayList<Schema.FieldSchema>();
          for (final GoodwillSchemaField field : schema.getSchema()) {
              schemaList.add(new Schema.FieldSchema(field.getName(), getPigType(field.getType())));
          }
  
          return new ResourceSchema(new Schema(schemaList));
      }
docs: Get a schema for the data to be loaded.
  
  @param location Location as returned by
  {@link org.apache.pig.LoadFunc#relativeToAbsolutePath(String, org.apache.hadoop.fs.Path)}
  @param job      The {@link org.apache.hadoop.mapreduce.Job} object - this should be used only to obtain
  cluster properties through {@link org.apache.hadoop.mapreduce.Job#getConfiguration()} and not to set/query
  any runtime job information.
  @return schema for the data to be loaded. This schema should represent
  all tuples of the returned data.  If the schema is unknown or it is
  not possible to return a schema that represents all returned data,
  then null should be returned. The schema should not be affected by pushProjection, ie.
  getSchema should always return the original schema even after pushProjection
  @throws java.io.IOException if an exception occurs while determining the schema