Exemple #1
0
        private static RowEntry ConvertToRowEntry(AclTableEntry.ModifyOperation aclModifyOperation)
        {
            switch (aclModifyOperation.Operation)
            {
            case ModifyTableOperationType.Add:
                return(RowEntry.Add(new PropValue[]
                {
                    new PropValue(PropTag.EntryId, aclModifyOperation.Entry.MemberEntryId),
                    new PropValue(PropTag.MemberRights, aclModifyOperation.Entry.MemberRights)
                }));

            case ModifyTableOperationType.Modify:
                return(RowEntry.Modify(new PropValue[]
                {
                    new PropValue(PropTag.MemberId, aclModifyOperation.Entry.MemberId),
                    new PropValue(PropTag.MemberRights, aclModifyOperation.Entry.MemberRights)
                }));

            case ModifyTableOperationType.Remove:
                return(RowEntry.Remove(new PropValue[]
                {
                    new PropValue(PropTag.MemberId, aclModifyOperation.Entry.MemberId)
                }));

            default:
                return(RowEntry.Empty());
            }
        }
Exemple #2
0
 public static RowEntry Add(byte[] memberEntryId, int rights)
 {
     PropValue[] propValues = new PropValue[]
     {
         new PropValue(PropTag.EntryId, memberEntryId),
         new PropValue(PropTag.MemberRights, rights)
     };
     return(RowEntry.Add(propValues));
 }