PCKRoleable

public protocol PCKRoleable : ParseRole

Objects that conform to the PCKRoleable protocol are ParseRole‘s .

  • appendString Default implementation

    The default string to be appended to the name. It is expected for each ParseRole to implement it’s own appendString.

    Default Implementation

    Declaration

    Swift

    static var appendString: String { get }
  • The owner of this ParseRole.

    Declaration

    Swift

    var owner: RoleUser? { get set }
  • roleName(owner:) Extension method

    Creates a name for the role by using appending appendString to the objectId.

    Throws

    An Error if the owner is missing the objectId.

    Declaration

    Swift

    static func roleName(owner: RoleUser?) throws -> String

    Parameters

    owner

    The owner of the ParseRole.

    Return Value

    The concatenated objectId and appendString.

  • create(with:) Extension method

    Creates a new private ParseRole with the owner having read/write permission.

    Throws

    An Error if the ParseRole cannot be created.

    Declaration

    Swift

    static func create(with owner: RoleUser) throws -> Self

    Parameters

    with

    The owner of the ParseRole.

    Return Value

    The new ParseRole.

  • merge(with:) Extension method

    Declaration

    Swift

    func merge(with object: Self) throws -> Self