Documentation
¶
Index ¶
- Constants
- type Accession
- type Cell
- type CrossReference
- type Date
- type Disease
- type Hierarchy
- type Marker
- type ObjectStore
- func (s *ObjectStore) CountCells() (int, error)
- func (s *ObjectStore) CountCrossReferences() (int, error)
- func (s *ObjectStore) CountReferences() (int, error)
- func (s *ObjectStore) FetchCell(attribute string) (*Cell, error)
- func (s *ObjectStore) ListCells(from, to int) ([]*Cell, error)
- func (s *ObjectStore) ListCrossReferences() ([]*XRef, error)
- func (s *ObjectStore) ListReferences(from, to int) ([]*Reference, error)
- func (s *ObjectStore) ListStatistics(version string) (*Statistics, error)
- type Reference
- type STR
- type SameOriginAs
- type SpeciesOfOrigin
- type Statistics
- type XRef
Constants ¶
const ( ResourceTypeCell = "CELL" ResourceTypeRef = "REF" )
Resource types.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cell ¶
type Cell struct {
Identifier string `json:"identifier"`
Accession Accession `json:"accession"`
Synonyms []string `json:"synonyms,omitempty"`
CrossReferences []CrossReference `json:"crossReferences,omitempty"`
References []string `json:"references,omitempty"`
WebPages []string `json:"webPages,omitempty"`
Comments []string `json:"comments,omitempty"`
STR STR `json:"strProfileData,omitempty"`
Diseases []Disease `json:"diseases,omitempty"`
SpeciesOfOrigin []SpeciesOfOrigin `json:"speciesOfOrigin"`
Hierarchy []Hierarchy `json:"hierarchy,omitempty"`
SameOriginAs []SameOriginAs `json:"sameOriginAs,omitempty"`
Sex string `json:"sex,omitempty"`
Age string `json:"age,omitempty"`
Category string `json:"category"`
Date Date `json:"date"`
}
type CrossReference ¶
type ObjectStore ¶
type ObjectStore struct {
// contains filtered or unexported fields
}
ObjectStore provides an API for interacting with the data store that contains the ingested Cellosaurus data.
func NewObjectStore ¶
func NewObjectStore(client *db.MySQLClient) *ObjectStore
NewObjectStore creates a new ObjectStore.
func (*ObjectStore) CountCells ¶
func (s *ObjectStore) CountCells() (int, error)
CountCells returns the total number of cell lines.
func (*ObjectStore) CountCrossReferences ¶
func (s *ObjectStore) CountCrossReferences() (int, error)
CountCrossReferences returns the total number of cross-references.
func (*ObjectStore) CountReferences ¶
func (s *ObjectStore) CountReferences() (int, error)
CountReferences returns the total number of references.
func (*ObjectStore) FetchCell ¶
func (s *ObjectStore) FetchCell(attribute string) (*Cell, error)
FetchCell retrieves a cell line using its attribute. Attribute can be oneof: ["accession", "identifier", "synonym"].
func (*ObjectStore) ListCells ¶
func (s *ObjectStore) ListCells(from, to int) ([]*Cell, error)
ListCells returns a list of cell lines from the store.
func (*ObjectStore) ListCrossReferences ¶
func (s *ObjectStore) ListCrossReferences() ([]*XRef, error)
ListXRefs returns a list of cross-references.
func (*ObjectStore) ListReferences ¶
func (s *ObjectStore) ListReferences(from, to int) ([]*Reference, error)
ListReferences returns a list of paginated references.
func (*ObjectStore) ListStatistics ¶
func (s *ObjectStore) ListStatistics(version string) (*Statistics, error)
ListStatistics returns a list of Cellosaurus data stats.