1 23 24 29 30 package com.sun.enterprise.deployment.runtime.connector; 31 32 import com.sun.enterprise.deployment.runtime.RuntimeDescriptor; 33 34 41 42 public class MapElement extends RuntimeDescriptor 43 { 44 45 static public final String PRINCIPAL = "Principal"; static public final String BACKEND_PRINCIPAL = "BackendPrincipal"; 48 Principal backendPrincipal = null; 49 50 public MapElement(MapElement other) 52 { 53 super(other); 54 } 55 56 public MapElement() 58 { 59 super(); 60 } 61 62 public void setPrincipal(int index, Principal value) 64 { 65 this.setValue(PRINCIPAL, index, value); 66 } 67 68 public Principal getPrincipal(int index) 70 { 71 return (Principal)this.getValue(PRINCIPAL, index); 72 } 73 74 public void setPrincipal(Principal[] value) 76 { 77 this.setValue(PRINCIPAL, value); 78 } 79 80 public Principal[] getPrincipal() 82 { 83 return (Principal[])this.getValues(PRINCIPAL); 84 } 85 86 public int sizePrincipal() 88 { 89 return this.size(PRINCIPAL); 90 } 91 92 public int addPrincipal(Principal value) 94 { 95 return this.addValue(PRINCIPAL, value); 96 } 97 98 public int removePrincipal(Principal value) 103 { 104 return this.removeValue(PRINCIPAL, value); 105 } 106 107 public void setBackendPrincipal(boolean value) 109 { 110 this.setValue(BACKEND_PRINCIPAL, new Boolean (value)); 111 } 112 113 public boolean isBackendPrincipal() 115 { 116 Boolean ret = (Boolean )this.getValue(BACKEND_PRINCIPAL); 117 if (ret == null) 118 return false; 119 return ret.booleanValue(); 120 } 121 122 public boolean verify() 124 { 125 return true; 126 } 127 } 128 | Popular Tags |