def load_schema(self, schema_file):
    """Load relation type declarations from a file.

    Each line in the file tab-separated with fields

      relation_name domain_type range_type

    Args:
      schema_file: a file_like object

    Raises:
      ValueError: If a line is formatted wrong.
    """
    with open(schema_file) as fp:
      for line in io.lines_in(fp):
        parts = line.strip().split('\t')
        if len(parts) != 3:
          raise ValueError('invalid type declaration %r' % line.strip())
        self.declare_relation(parts[0], parts[1], parts[2])
Load relation type declarations from a file.

    Each line in the file tab-separated with fields

      relation_name domain_type range_type

    Args:
      schema_file: a file_like object

    Raises:
      ValueError: If a line is formatted wrong.
    
language/nql/nql/__init__.py