Novell.Directory.Ldap.Rfc2251.RfcFilter.startNestedFilter C# (CSharp) Method

startNestedFilter() public method

Creates and adds the Asn1Tagged value for a nestedFilter: AND, OR, or NOT. Note that a Not nested filter can only have one filter, where AND and OR do not
public startNestedFilter ( int rfcType ) : void
rfcType int Filter type: /// [AND | OR | NOT] /// @throws Novell.Directory.Ldap.LdapLocalException ///
return void
        public virtual void startNestedFilter(int rfcType)
        {
            Asn1Object current;
            if (rfcType == AND || rfcType == OR)
            {
                current = new Asn1Tagged(new Asn1Identifier(Asn1Identifier.CONTEXT, true, rfcType), new Asn1SetOf(), false);
            }
            else if (rfcType == NOT)
            {
                current = new Asn1Tagged(new Asn1Identifier(Asn1Identifier.CONTEXT, true, rfcType), null, true);
            }
            else
            {
                throw new LdapLocalException("Attempt to create a nested filter other than AND, OR or NOT", LdapException.FILTER_ERROR);
            }
            addObject(current);
            return ;
        }