Part

semagrams.acsets.Part
case class Part(path: Seq[(Ob, Id)]) extends Entity

A part is a path through a nested acset. If you visualize a nested acset as a tree, where each node is an acset and its children are all of its subacsets, then a part tells at each level which subacset to choose.

The empty path refers to the root acset.

Attributes

Todo:

We should have "relative" parts and "absolute" parts, just like in a filesystem there are relative and absolute paths. I think that currently Part is used for both notions, which is very confusing.

Graph
Supertypes
trait Serializable
trait Product
trait Equals
trait Entity
class Object
trait Matchable
class Any

Members list

Concise view

Value members

Concrete methods

def -(that: Part): Part

Returns p if this == that.extendPart(p), else errors

Returns p if this == that.extendPart(p), else errors

Attributes

def <(that: Part): Boolean

Checks if that is more specific than this

Checks if that is more specific than this

Attributes

def >(that: Part): Boolean

Checks if this is more specific than that

Checks if this is more specific than that

Attributes

def diffOption(that: Part): Option[Part]

Returns Some(p) if this == that.extendPart(p), else None

Returns Some(p) if this == that.extendPart(p), else None

Attributes

def extend(x: Ob, i: Id): Part

Provide directions to go one acset deeper

Provide directions to go one acset deeper

Attributes

Overload to return a Part rather than Entity

Overload to return a Part rather than Entity

Attributes

def hasFinal(ptype: PartType): Boolean

Checks if ptype is an final segment of ty

Checks if ptype is an final segment of ty

Attributes

def hasInitial(ptype: PartType): Boolean

Checks if ptype is an initial segment of ty

Checks if ptype is an initial segment of ty

Attributes

def head: Part

Returns the first part in the path

Returns the first part in the path

Attributes

def headId: Id

Returns the first id in the path

Returns the first id in the path

Attributes

def headOb: Ob

Returns the first object in the path

Returns the first object in the path

Attributes

def init: Part

Returns the initial segment of the path

Returns the initial segment of the path

Attributes

def last: Part

Returns the last part of the path

Returns the last part of the path

Attributes

def lastId: Id

Returns the last id in the path

Returns the last id in the path

Attributes

def lastOb: Ob

Returns the last object in the path

Returns the last object in the path

Attributes

def tail: Part

Returns the tail segment of a part

Returns the tail segment of a part

Attributes

def tikzName: String

Transform to an name that is usable in tikz

Transform to an name that is usable in tikz

Attributes

Inherited methods

def extend(sub: Entity): Entity

Construct a subentity of this entity

Construct a subentity of this entity

Attributes

Inherited from:
Entity
def productElementNames: Iterator[String]

Attributes

Inherited from:
Product
def productIterator: Iterator[Any]

Attributes

Inherited from:
Product

Concrete fields

override val ty: PartType

All of the objects of the path

All of the objects of the path

Attributes