Class PLPrincipal

java.lang.Object
org.postgresql.pljava.PLPrincipal
All Implemented Interfaces:
Serializable, Principal
Direct Known Subclasses:
PLPrincipal.Sandboxed, PLPrincipal.Unsandboxed

public abstract class PLPrincipal
extends Object
Java Principal representing a PostgreSQL PROCEDURAL LANGUAGE, which has a name (a simple identifier, not schema-qualified) and is either Sandboxed (declared with SQL CREATE TRUSTED LANGUAGE or Unsandboxed.

Only the subclasses, Sandboxed or Unsandboxed can be instantiated, or granted permissions in policy.

See Also:
Serialized Form
  • Nested Class Summary

    Nested Classes
    Modifier and Type Class Description
    static class  PLPrincipal.Sandboxed
    Java Principal representing a PostgreSQL PROCEDURAL LANGUAGE that was declared with the TRUSTED keyword and can be used to declare new functions by any role that has been granted USAGE permission on it.
    static class  PLPrincipal.Unsandboxed
    Java Principal representing a PostgreSQL PROCEDURAL LANGUAGE that was declared without the TRUSTED keyword, and can be used to declare new functions only by a PostgreSQL superuser.
  • Method Summary

    Modifier and Type Method Description
    boolean equals​(Object other)  
    String getName()  
    int hashCode()  
    String toString()  
    abstract Function.Trust trust()
    Returns either SANDBOXED or UNSANDBOXED according to PostgreSQL's catalog entry for the language.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface java.security.Principal

    implies