{
    "content": [
        {
            "type": "text",
            "text": "# Net::LDAP::Control (info)\n\n## NAME\n\nNet::LDAP::Control - LDAPv3 control object base class\n\n## SYNOPSIS\n\nuse Net::LDAP::Control;\nuse Net::LDAP::Constant qw( LDAPCONTROLMANAGEDSAIT );\nmy $reqctrl1 = Net::LDAP::Control->new( type => LDAPCONTROLMANAGEDSAIT );\nmy $reqctrl2 = Net::LDAP::Control->new(\ntype     => \"1.2.3.4\",\nvalue    => \"help\",\ncritical => 0\n);\n$mesg = $ldap->search( @args, control => [ $reqctrl1, $reqctrl2 ]);\nmy @resctrls = $mesg->control();\n\n## DESCRIPTION\n\n\"Net::LDAP::Control\" is the base-class for LDAPv3 control objects.\n\n## Sections\n\n- **Net::LDAP::Control(3pmUser Contributed Perl DocumentatiNet::LDAP::Control(3pm)**\n- **NAME**\n- **SYNOPSIS**\n- **DESCRIPTION**\n- **CONSTRUCTORS**\n- **METHODS**\n- **SEE ALSO**\n- **AUTHOR**\n- **COPYRIGHT**\n\nUse structuredContent.sections for detailed options, examples, and full documentation.\n"
        }
    ],
    "structuredContent": {
        "command": "Net::LDAP::Control",
        "section": "",
        "mode": "info",
        "summary": "Net::LDAP::Control - LDAPv3 control object base class",
        "synopsis": "use Net::LDAP::Control;\nuse Net::LDAP::Constant qw( LDAPCONTROLMANAGEDSAIT );\nmy $reqctrl1 = Net::LDAP::Control->new( type => LDAPCONTROLMANAGEDSAIT );\nmy $reqctrl2 = Net::LDAP::Control->new(\ntype     => \"1.2.3.4\",\nvalue    => \"help\",\ncritical => 0\n);\n$mesg = $ldap->search( @args, control => [ $reqctrl1, $reqctrl2 ]);\nmy @resctrls = $mesg->control();",
        "tldr_summary": null,
        "tldr_examples": [],
        "tldr_source": null,
        "flags": [],
        "examples": [],
        "see_also": [],
        "section_outline": [
            {
                "name": "Net::LDAP::Control(3pmUser Contributed Perl DocumentatiNet::LDAP::Control(3pm)",
                "lines": 1,
                "subsections": []
            },
            {
                "name": "NAME",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "SYNOPSIS",
                "lines": 14,
                "subsections": []
            },
            {
                "name": "DESCRIPTION",
                "lines": 15,
                "subsections": []
            },
            {
                "name": "CONSTRUCTORS",
                "lines": 44,
                "subsections": []
            },
            {
                "name": "METHODS",
                "lines": 48,
                "subsections": []
            },
            {
                "name": "SEE ALSO",
                "lines": 12,
                "subsections": []
            },
            {
                "name": "AUTHOR",
                "lines": 5,
                "subsections": []
            },
            {
                "name": "COPYRIGHT",
                "lines": 5,
                "subsections": []
            }
        ],
        "sections": {
            "Net::LDAP::Control(3pmUser Contributed Perl DocumentatiNet::LDAP::Control(3pm)": {
                "content": "",
                "subsections": []
            },
            "NAME": {
                "content": "Net::LDAP::Control - LDAPv3 control object base class\n",
                "subsections": []
            },
            "SYNOPSIS": {
                "content": "use Net::LDAP::Control;\nuse Net::LDAP::Constant qw( LDAPCONTROLMANAGEDSAIT );\n\nmy $reqctrl1 = Net::LDAP::Control->new( type => LDAPCONTROLMANAGEDSAIT );\nmy $reqctrl2 = Net::LDAP::Control->new(\ntype     => \"1.2.3.4\",\nvalue    => \"help\",\ncritical => 0\n);\n\n$mesg = $ldap->search( @args, control => [ $reqctrl1, $reqctrl2 ]);\n\nmy @resctrls = $mesg->control();\n",
                "subsections": []
            },
            "DESCRIPTION": {
                "content": "\"Net::LDAP::Control\" is the base-class for LDAPv3 control objects.\n\nControls provide a mechanism that allows one to extend the semantics\nand arguments of LDAP operations.  Controls may be attached to LDAP\noperations, and only affect the semantics of the operation they are\nattached to.\n\nControls sent by clients are termed request controls, and are set using\nthe \"control\" option of the respective LDAP operations.  Controls sent\nby servers are called response controls, they can be found using the\n\"control()\" method of the response message objects.\n\nServers announce the controls they support in the attribute\n\"supportedControls\" in their RootDSE.\n",
                "subsections": []
            },
            "CONSTRUCTORS": {
                "content": "new ( ARGS )\nARGS is a list of name/value pairs, valid arguments are:\n\ncritical\nA Boolean value, if TRUE and the control is unrecognized by the\nserver or is inappropriate for the requested operation then the\nserver will return an error and the operation will not be\nperformed.\n\nIf FALSE and the control is unrecognized by the server or is\ninappropriate for the requested operation then the server will\nignore the control and perform the requested operation as if\nthe control was not given.\n\nIf absent, FALSE is assumed.\n\ntype\nA dotted-decimal representation of an OBJECT IDENTIFIER which\nuniquely identifies the control. This prevents conflicts\nbetween control names.\n\nThis may be omitted if the constructor is being called on a\nsub-class of Net::LDAP::Control which has registered to be\nassociated with an OID.  If the constructor is being called on\nthe Net::LDAP::Control package, then this argument must be\ngiven.  If the given OID has been registered by a package, then\nthe returned object will be of the type registered to handle\nthat OID.\n\nvalue\nOptional information associated with the control. Its format is\nspecific to the particular control.\n\nfromasn ( ASN )\nASN is a HASH reference, normally extracted from a PDU. It will\ncontain a \"type\" element and optionally \"critical\" and \"value\"\nelements. On return ASN will be blessed into a package. If \"type\"\nis a registered OID, then ASN will be blessed into the registered\npackage, if not then ASN will be blessed into Net::LDAP::Control.\n\nThis constructor is used internally by Net::LDAP and assumes that\nHASH passed contains a valid control. It should be used with\ncaution.\n",
                "subsections": []
            },
            "METHODS": {
                "content": "In addition to the methods listed below, each of the named parameters\nto \"new\" is also available as a method. \"type\" will return the OID of\nthe control object. \"value\" and \"critical\" are set/get methods and will\nreturn the current value for each attribute if called without\narguments, but may also be called with arguments to set new values.\n\nerror ()\nIf there has been an error returns a description of the error,\notherwise it will return \"undef\"\n\ninit ()\n\"init\" will be called as the last step in both constructors. What\nit does will depend on the sub-class. It must always return the\nobject.\n\nregister ( OID )\n\"register\" is provided for sub-class implementors. It should be\ncalled as a class method on a sub-class of Net::LDAP::Control with\nthe OID that the class will handle. Net::LDAP::Control will\nremember this class and OID pair and use it in the following\nsituations.\n\no   \"new\" is called as a class method on the Net::LDAP::Control\npackage and OID is passed as the type. The returned object will\nbe blessed into the package that registered the OID.\n\no   \"new\" is called as a class method on a registered package and\nthe \"type\" is not specified. The \"type\" will be set to the OID\nregistered by that package.\n\no   \"fromasn\" is called to construct an object from ASN. The\nreturned object will be blessed into the package which was\nregistered to handle the OID in the ASN.\n\n( toasn )\nReturns a structure suitable for passing to Convert::ASN1 for\nencoding. This method will be called by Net::LDAP when the control\nis used.\n\nThe base class implementation of this method will call the \"value\"\nmethod without arguments to allow a sub-class to encode it's value.\nSub-classes should not need to override this method.\n\nvalid ()\nReturns true if the object is valid and can be encoded. The default\nimplementation for this method is to return TRUE if there is no\nerror, but sub-classes may override that.\n",
                "subsections": []
            },
            "SEE ALSO": {
                "content": "Net::LDAP, Net::LDAP::RootDSE, Net::LDAP::Control::Assertion,\nNet::LDAP::Control::DontUseCopy, Net::LDAP::Control::EntryChange,\nNet::LDAP::Control::ManageDsaIT, Net::LDAP::Control::MatchedValues,\nNet::LDAP::Control::Paged, Net::LDAP::Control::PasswordPolicy,\nNet::LDAP::Control::PersistentSearch, Net::LDAP::Control::PostRead,\nNet::LDAP::Control::PreRead, Net::LDAP::Control::ProxyAuth,\nNet::LDAP::Control::Relax, Net::LDAP::Control::Sort,\nNet::LDAP::Control::SortResult, Net::LDAP::Control::SyncDone,\nNet::LDAP::Control::SyncRequest, Net::LDAP::Control::SyncState,\nNet::LDAP::Control::TreeDelete, Net::LDAP::Control::VLV,\nNet::LDAP::Control::VLVResponse\n",
                "subsections": []
            },
            "AUTHOR": {
                "content": "Graham Barr <gbarr@pobox.com>\n\nPlease report any bugs, or post any suggestions, to the perl-ldap\nmailing list <perl-ldap@perl.org>\n",
                "subsections": []
            },
            "COPYRIGHT": {
                "content": "Copyright (c) 1999-2004 Graham Barr. All rights reserved. This program\nis free software; you can redistribute it and/or modify it under the\nsame terms as Perl itself.\n\nperl v5.32.0                      2021-01-03           Net::LDAP::Control(3pm)",
                "subsections": []
            }
        }
    }
}