arxiv.canonical.domain.identifier module¶
Provides the concept of an arXiv identifier.
-
class
arxiv.canonical.domain.identifier.
Identifier
(value)[source]¶ Bases:
str
An arXiv e-print identifier.
Supports both old-style (
archive.category/YYMMNNN
) and new-style (YYMM.NNNNN
) identifiers.-
classmethod
from_parts
(year, month, inc)[source]¶ Generate a new-style identifier from its parts.
- Return type
-
property
numeric_part
¶ The entire numeric component of the identifier.
For new-style identifiers, this is the entire identifier.
- Return type
-
classmethod
-
exception
arxiv.canonical.domain.identifier.
InvalidIdentifier
[source]¶ Bases:
ValueError
A value was encountered that is not a valid arXiv identifier.
-
class
arxiv.canonical.domain.identifier.
VersionedIdentifier
(value)[source]¶ Bases:
str
An arXiv identifier for a specific
Version
.This is an
Identifier
with a version (v{N}
) affix.-
classmethod
from_parts
(arxiv_id, version)[source]¶ Generate a new-style versioned identifier from its parts.
- Return type
-
property
numeric_part
¶ The entire numeric component of the identifier.
For new-style identifiers, this is the entire identifier.
- Return type
-
classmethod