TypeDef

class pyobo.TypeDef(reference, comment=None, namespace=None, definition=None, is_transitive=None, is_symmetric=None, domain=None, range=None, parents=<factory>, xrefs=<factory>, inverse=None, created_by=None, holds_over_chain=None, is_metadata_tag=None)[source]

Bases: Referenced

A type definition in OBO.

Attributes Summary

comment

created_by

definition

domain

holds_over_chain

inverse

is_metadata_tag

Whether this relationship is a metadata tag.

is_symmetric

is_transitive

namespace

range

Methods Summary

from_curie(curie[, name])

Create a TypeDef directly from a CURIE and optional name.

from_triple(prefix, identifier[, name])

Create a typedef from a reference.

iterate_obo_lines()

Iterate over the lines to write in an OBO file.

Attributes Documentation

comment: Optional[str] = None
created_by: Optional[str] = None
definition: Optional[str] = None
domain: Optional[Reference] = None
holds_over_chain: Optional[List[Reference]] = None
inverse: Optional[Reference] = None
is_metadata_tag: Optional[bool] = None

Whether this relationship is a metadata tag. Properties that are marked as metadata tags are used to record object metadata. Object metadata is additional information about an object that is useful to track, but does not impact the definition of the object or how it should be treated by a reasoner. Metadata tags might be used to record special term synonyms or structured notes about a term, for example.

is_symmetric: Optional[bool] = None
is_transitive: Optional[bool] = None
namespace: Optional[str] = None
range: Optional[Reference] = None

Methods Documentation

classmethod from_curie(curie, name=None)[source]

Create a TypeDef directly from a CURIE and optional name.

Return type:

TypeDef

classmethod from_triple(prefix, identifier, name=None)[source]

Create a typedef from a reference.

Return type:

TypeDef

iterate_obo_lines()[source]

Iterate over the lines to write in an OBO file.

Return type:

Iterable[str]