sightline.simon.prototype — Prototype API

class sightline.simon.prototype.Prototype[source]

Attributes

  • Prototype.id: str
  • Prototype.type: str
  • Prototype.name: str
  • Prototype.description: str
  • Prototype.tags: List[str]
  • Prototype.created: datetime
  • Prototype.capabilities: List[Capability]
  • Prototype.dependencies: List[Prototype]

Class Methods

  • Prototype.list()[source]

    Returns all Prototypes of any type. If you’re only concerned with a Prototype of specific types, you can use the Servable.prototypes() classmethod instead to return Prototypes of only that Servable type.

    Classmethod

    Return type

    List[Prototype]

  • Prototype.from_id(id)[source]

    A constructor for Prototypes. In place of id you can also pass in name:tag from the Docker image for this Prototype. This allows lookup of Prototype id from the Docker image.

    Classmethod

    Parameters

    id (str) –

    Return type

    Prototype

    Raises

    TypeError – if not called with an appropriate Servable class

  • Prototype.remove(*id)[source]

    Removes the Prototypes corresponding to the passed in id. name:tag can be used in place of id. Will only remove Prototypes that have no other Prototypes dependent on them, and will not remove any Prototypes if any of the passed in Prototypes cannot be removed.

    Classmethod

    Parameters

    id (str) – A Prototype id

    Return type

    None