add

fun add(entity: T, value: R): Boolean

Adds a relation A -> B if domain does not contain A and coDomain does not contain B. Returns false if the relation could not be added.

Return

true if the element was added to the map, false otherwise.

See also


fun add(element: Pair<T, R>): Boolean

Adds a relation A -> B if domain does not contain A and coDomain does not contain B. Returns false if the relation could not be added.

Return

true if the element was added to the map or already existed, false otherwise.

See also