Ejemplo n.º 1
0
        public bool IsOwner(string psOwner)
        {
            if (String.IsNullOrEmpty(psOwner))
            {
                throw new WonkaBrePermissionsException("ERROR!  Provided owner cannot be null or blank.");
            }

            return(OwnerWeights.ContainsKey(psOwner));
        }
Ejemplo n.º 2
0
        public void RemoveOwner(string psOwner)
        {
            if (!IsOwner(psOwner))
            {
                throw new WonkaBrePermissionsException("ERROR!  Account(" + psOwner + ") is not a registered owner that is associated with this RuleTree.");
            }

            OwnerWeights.Remove(psOwner);
            OwnerConfirmations.Remove(psOwner);
        }
Ejemplo n.º 3
0
 public uint GetOwnerWeight(string psOwner)
 {
     if (!String.IsNullOrEmpty(psOwner))
     {
         if (OwnerWeights.ContainsKey(psOwner))
         {
             return(OwnerWeights[psOwner]);
         }
         else
         {
             return(0);
         }
     }
     else
     {
         return(0);
     }
 }