1 21 22 package org.apache.derby.iapi.sql.conn; 23 24 import org.apache.derby.iapi.sql.Activation; 25 import org.apache.derby.iapi.error.StandardException; 26 34 public interface Authorizer 35 { 36 37 public static final int SQL_WRITE_OP = 0; 38 39 public static final int SQL_SELECT_OP = 1; 40 41 public static final int SQL_ARBITARY_OP = 2; 42 43 public static final int SQL_CALL_OP = 3; 44 45 public static final int SQL_DDL_OP = 4; 46 47 public static final int PROPERTY_WRITE_OP = 5; 48 49 public static final int JAR_WRITE_OP = 6; 50 51 52 public static final int NULL_PRIV = -1; 53 public static final int SELECT_PRIV = 0; 54 public static final int UPDATE_PRIV = 1; 55 public static final int REFERENCES_PRIV = 2; 56 public static final int INSERT_PRIV = 3; 57 public static final int DELETE_PRIV = 4; 58 public static final int TRIGGER_PRIV = 5; 59 public static final int EXECUTE_PRIV = 6; 60 public static final int PRIV_TYPE_COUNT = 7; 61 62 63 public static final int CREATE_SCHEMA_PRIV = 16; 64 public static final int MODIFY_SCHEMA_PRIV = 17; 65 public static final int DROP_SCHEMA_PRIV = 18; 66 67 71 public static final String SYSTEM_AUTHORIZATION_ID = "_SYSTEM"; 72 73 76 public static final String PUBLIC_AUTHORIZATION_ID = "PUBLIC"; 77 78 91 public void authorize( int operation) throws StandardException; 92 93 102 public void authorize(Activation activation, int operation) 103 throws StandardException; 104 105 108 public String getAuthorizationId(); 109 110 113 public boolean isReadOnlyConnection(); 114 115 123 public void setReadOnlyConnection(boolean on, boolean authorize) 124 throws StandardException; 125 126 133 public void refresh() throws StandardException; 134 } 135 | Popular Tags |