Package nexj.core.meta

Examples of nexj.core.meta.Privilege


      m_metadata = Repository.getMetadata();
      m_context = new InvocationContext(m_metadata);

      for (Iterator itr = m_metadata.getPrivilegeIterator(); itr.hasNext();)
      {
         Privilege p = (Privilege)itr.next();

         if (p instanceof PrimitivePrivilege)
         {
            m_context.getPrivilegeSet().add((PrimitivePrivilege)p);
         }
View Full Code Here


            XMLUtil.forEachChildElement(privilegesElement, "Privilege",
               m_helper.new ElementHandler("privilege")
            {
               public void handleElement(Element privilegeElement, String sPrivilegeName)
               {
                  Privilege privilege = new PrimitivePrivilege(sPrivilegeName);

                  m_metadata.addPrivilege(privilege);
                  privilege.setCaption(XMLUtil.getStringAttr(privilegeElement,
                     "caption", privilege.getCaption()));
               }
            });
         }
      });
View Full Code Here

   public void setStealth(boolean bStealth)
   {
      // Check stealth privilege
      if (bStealth && m_bSecure && m_privilegeSet != null)
      {
         Privilege privilege = m_metadata.findPrivilege("Debug");

         if (!(privilege instanceof PrimitivePrivilege) ||
            !m_privilegeSet.contains((PrimitivePrivilege)privilege))
         {
            m_bStealth = false;
View Full Code Here

    * @return The privilege object.
    * @throws MetadataLookupException if the privilege does not exist.
    */
   public Privilege getPrivilege(String sName)
   {
      Privilege privilege = (Privilege)m_privilegeMap.get(sName);

      if (privilege != null)
      {
         return privilege;
      }
View Full Code Here

   /**
    * @see nexj.core.meta.Metadata#getPrimitivePrivilege(java.lang.String)
    */
   public PrimitivePrivilege getPrimitivePrivilege(String sName)
   {
      Privilege privilege = (Privilege) m_privilegeMap.get(sName);

      if (privilege != null && privilege.isPrimitive())
      {
         return (PrimitivePrivilege)privilege;
      }

      throw new MetadataLookupException("err.meta.privilegeLookup", sName, this);
View Full Code Here

TOP

Related Classes of nexj.core.meta.Privilege

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.