docs::a...R::Const(3)
πΈ NAME πΈ
APR::Const β Perl Interface for APR Constants. This is the manual page docs::a...R::Const(3), from User Contributed Perl Documentation, and it's basically the constant stash for APR stuff. π
β¨ Synopsis β¨
# make the constants available but don't import them
use APR::Const -compile => qw(constant names ...);
# w/o the => syntax sugar
use APR::Const ("-compile", qw(constant names ...));
# compile and import the constants
use APR::Const qw(constant names ...);
Three ways to summon the constants, bestie. Pick your vibe. π«Ά
π¦ Description π¦
This package contains constants specific to APR features.
Refer to the Apache2::Const description section for more information.
π Constants π
π :common π
use APR::Const -compile => qw(:common);
The :common group is for XXX constants. (Yes, the page literally says XXX β no cap, that's what's here. π)
APR::Const::SUCCESSβ since:2.0.00
π :error π
use APR::Const -compile => qw(:error);
The :error group is for XXX constants.
APR::Const::EABOVEROOTβ since:2.0.00APR::Const::EABSOLUTEβ since:2.0.00APR::Const::EACCESβ since:2.0.00. Due to possible variants in conditions matchingEACCES, for checking error codes against this you most likely want to use theAPR::Status::is_EACCESfunction instead.APR::Const::EAGAINβ since:2.0.00. The errorResource temporarily unavailable, may be returned by many different system calls, especially IO calls. Most likely you want to use theAPR::Status::is_EAGAINfunction instead.APR::Const::EBADDATEβ since:2.0.00APR::Const::EBADFβ since:2.0.00APR::Const::EBADIPβ since:2.0.00APR::Const::EBADMASKβ since:2.0.00APR::Const::EBADPATHβ since:2.0.00APR::Const::EBUSYβ since:2.0.00APR::Const::ECONNABORTEDβ since:2.0.00. Due to possible variants in conditions matchingECONNABORTED, for checking error codes against this you most likely want to use theAPR::Status::is_ECONNABORTEDfunction instead.APR::Const::ECONNREFUSEDβ since:2.0.00APR::Const::ECONNRESETβ since:2.0.00. Due to possible variants in conditions matchingECONNRESET, for checking error codes against this you most likely want to use theAPR::Status::is_ECONNRESETfunction instead.APR::Const::EDSOOPENβ since:2.0.00APR::Const::EEXISTβ since:2.0.00APR::Const::EFTYPEβ since:2.0.00APR::Const::EGENERALβ since:2.0.00APR::Const::EHOSTUNREACHβ since:2.0.00APR::Const::EINCOMPLETEβ since:2.0.00APR::Const::EINITβ since:2.0.00APR::Const::EINPROGRESSβ since:2.0.00APR::Const::EINTRβ since:2.0.00APR::Const::EINVALβ since:2.0.00APR::Const::EINVALSOCKβ since:2.0.00APR::Const::EMFILEβ since:2.0.00APR::Const::EMISMATCHβ since:2.0.00APR::Const::ENAMETOOLONGβ since:2.0.00APR::Const::ENDβ since:2.0.00APR::Const::ENETUNREACHβ since:2.0.00APR::Const::ENFILEβ since:2.0.00APR::Const::ENODIRβ since:2.0.00APR::Const::ENOENTβ since:2.0.00. Due to possible variants in conditions matchingENOENT, for checking error codes against this you most likely want to use theAPR::Status::is_ENOENTfunction instead.APR::Const::ENOLOCKβ since:2.0.00APR::Const::ENOMEMβ since:2.0.00APR::Const::ENOPOLLβ since:2.0.00APR::Const::ENOPOOLβ since:2.0.00APR::Const::ENOPROCβ since:2.0.00APR::Const::ENOSHMAVAILβ since:2.0.00APR::Const::ENOSOCKETβ since:2.0.00APR::Const::ENOSPCβ since:2.0.00APR::Const::ENOSTATβ since:2.0.00APR::Const::ENOTDIRβ since:2.0.00APR::Const::ENOTEMPTYβ since:2.0.00APR::Const::ENOTHDKEYβ since:2.0.00APR::Const::ENOTHREADβ since:2.0.00APR::Const::ENOTIMEβ since:2.0.00APR::Const::ENOTIMPLβ Something is not implemented. since:2.0.00APR::Const::ENOTSOCKβ since:2.0.00APR::Const::EOFβ since:2.0.00. Due to possible variants in conditions matchingEOF, for checking error codes against this you most likely want to use theAPR::Status::is_EOFfunction instead.APR::Const::EPATHWILDβ since:2.0.00APR::Const::EPIPEβ since:2.0.00APR::Const::EPROC_UNKNOWNβ since:2.0.00APR::Const::ERELATIVEβ since:2.0.00APR::Const::ESPIPEβ since:2.0.00APR::Const::ESYMNOTFOUNDβ since:2.0.00APR::Const::ETIMEDOUTβ since:2.0.00APR::Const::EXDEVβ since:2.0.00
π¦ :fopen π¦
use APR::Const -compile => qw(:fopen);
The :fopen group is for XXX constants.
APR::Const::FOPEN_BINARYβ since:2.0.00APR::Const::FOPEN_BUFFEREDβ since:2.0.00APR::Const::FOPEN_CREATEβ since:2.0.00APR::Const::FOPEN_DELONCLOSEβ since:2.0.00APR::Const::FOPEN_EXCLβ since:2.0.00APR::Const::FOPEN_PENDβ since:2.0.00APR::Const::FOPEN_READβ since:2.0.00APR::Const::FOPEN_TRUNCATEβ since:2.0.00APR::Const::FOPEN_WRITEβ since:2.0.00
πΈ :filepath πΈ
use APR::Const -compile => qw(:filepath);
The :filepath group is for XXX constants.
APR::Const::FILEPATH_ENCODING_LOCALEβ since:2.0.00APR::Const::FILEPATH_ENCODING_UNKNOWNβ since:2.0.00APR::Const::FILEPATH_ENCODING_UTF8β since:2.0.00APR::Const::FILEPATH_NATIVEβ since:2.0.00APR::Const::FILEPATH_NOTABOVEROOTβ since:2.0.00APR::Const::FILEPATH_NOTABSOLUTEβ since:2.0.00APR::Const::FILEPATH_NOTRELATIVEβ since:2.0.00APR::Const::FILEPATH_SECUREROOTβ since:2.0.00APR::Const::FILEPATH_SECUREROOTTESTβ since:2.0.00APR::Const::FILEPATH_TRUENAMEβ since:2.0.00
π :fprot π
use APR::Const -compile => qw(:fprot);
The :fprot group is used by $finfo->protection.
APR::Const::FPROT_GEXECUTEβ Execute by group. since:2.0.00APR::Const::FPROT_GREADβ Read by group. since:2.0.00APR::Const::FPROT_GSETIDβ Set group id. since:2.0.00APR::Const::FPROT_GWRITEβ Write by group. since:2.0.00APR::Const::FPROT_OS_DEFAULTβ use OS's default permissions. since:2.0.00APR::Const::FPROT_UEXECUTEβ Execute by user. since:2.0.00APR::Const::FPROT_UREADβ Read by user. since:2.0.00APR::Const::FPROT_USETIDβ Set user id. since:2.0.00APR::Const::FPROT_UWRITEβ Write by user. since:2.0.00APR::Const::FPROT_WEXECUTEβ Execute by others. since:2.0.00APR::Const::FPROT_WREADβ Read by others. since:2.0.00APR::Const::FPROT_WSTICKYβ Sticky bit. since:2.0.00APR::Const::FPROT_WWRITEβ Write by others. since:2.0.00
π§ :filetype π§
use APR::Const -compile => qw(:filetype);
The :filetype group is used by $finfo->filetype.
APR::Const::FILETYPE_BLKβ a file is a block device. since:2.0.00APR::Const::FILETYPE_CHRβ a file is a character device. since:2.0.00APR::Const::FILETYPE_DIRβ a file is a directory. since:2.0.00APR::Const::FILETYPE_LNKβ a file is a symbolic link. since:2.0.00APR::Const::FILETYPE_NOFILEβ the file type is undedetermined. since:2.0.00APR::Const::FILETYPE_PIPEβ a file is a FIFO or a pipe. since:2.0.00APR::Const::FILETYPE_REGβ a file is a regular file. since:2.0.00APR::Const::FILETYPE_SOCKβ a file is a [unix domain] socket. since:2.0.00APR::Const::FILETYPE_UNKFILEβ a file is of some other unknown type or the type cannot be determined. since:2.0.00
π :finfo π
use APR::Const -compile => qw(:finfo);
The :finfo group is used by stat() and $finfo->valid.
APR::Const::FINFO_ATIMEβ Access Time. since:2.0.00APR::Const::FINFO_CSIZEβ Storage size consumed by the file. since:2.0.00APR::Const::FINFO_CTIMEβ Creation Time. since:2.0.00APR::Const::FINFO_DEVβ Device. since:2.0.00APR::Const::FINFO_DIRENTβ an atomic unix apr_dir_read(). since:2.0.00APR::Const::FINFO_GPROTβ Group protection bits. since:2.0.00APR::Const::FINFO_GROUPβ Group id. since:2.0.00APR::Const::FINFO_ICASEβ whether device is case insensitive. since:2.0.00APR::Const::FINFO_IDENTβ device and inode. since:2.0.00APR::Const::FINFO_INODEβ Inode. since:2.0.00APR::Const::FINFO_LINKβ Stat the link not the file itself if it is a link. since:2.0.00APR::Const::FINFO_MINβ type, mtime, ctime, atime, size. since:2.0.00APR::Const::FINFO_MTIMEβ Modification Time. since:2.0.00APR::Const::FINFO_NAMEβ name in proper case. since:2.0.00APR::Const::FINFO_NLINKβ Number of links. since:2.0.00APR::Const::FINFO_NORMβ All fields provided by an atomic unix apr_stat(). since:2.0.00APR::Const::FINFO_OWNERβ user and group. since:2.0.00APR::Const::FINFO_PROTβ all protections. since:2.0.00APR::Const::FINFO_SIZEβ Size of the file. since:2.0.00APR::Const::FINFO_TYPEβ Type. since:2.0.00APR::Const::FINFO_UPROTβ User protection bits. since:2.0.00APR::Const::FINFO_USERβ User id. since:2.0.00APR::Const::FINFO_WPROTβ World protection bits. since:2.0.00
π₯ :flock π₯
use APR::Const -compile => qw(:flock);
The :flock group is for XXX constants.
APR::Const::FLOCK_EXCLUSIVEβ since:2.0.00APR::Const::FLOCK_NONBLOCKβ since:2.0.00APR::Const::FLOCK_SHAREDβ since:2.0.00APR::Const::FLOCK_TYPEMASKβ since:2.0.00
π :hook π
use APR::Const -compile => qw(:hook);
The :hook group is for XXX constants.
APR::Const::HOOK_FIRSTβ since:2.0.00APR::Const::HOOK_LASTβ since:2.0.00APR::Const::HOOK_MIDDLEβ since:2.0.00APR::Const::HOOK_REALLY_FIRSTβ since:2.0.00APR::Const::HOOK_REALLY_LASTβ since:2.0.00
β :limit β
use APR::Const -compile => qw(:limit);
The :limit group is for XXX constants.
APR::Const::LIMIT_CPUβ since:2.0.00APR::Const::LIMIT_MEMβ since:2.0.00APR::Const::LIMIT_NOFILEβ since:2.0.00APR::Const::LIMIT_NPROCβ since:2.0.00
π :lockmech π
use APR::Const -compile => qw(:lockmech);
The :lockmech group is for XXX constants.
Okay bestie, picking up right where we left off β here come the rest of the constants, and they're serving π
APR::Const::LOCK_DEFAULTβ since: 2.0.00 β¨APR::Const::LOCK_FCNTLβ since: 2.0.00APR::Const::LOCK_FLOCKβ since: 2.0.00APR::Const::LOCK_POSIXSEMβ since: 2.0.00APR::Const::LOCK_PROC_PTHREADβ since: 2.0.00APR::Const::LOCK_SYSVSEMβ since: 2.0.00
:poll π
use APR::Const -compile => qw(:poll);
The :poll group is used by poll. (iykyk)
APR::Const::POLLERRβ since: 2.0.00 β Pending errorAPR::Const::POLLHUPβ since: 2.0.00 β Hangup occurredAPR::Const::POLLINβ since: 2.0.00 β Can read without blockingAPR::Const::POLLNVALβ since: 2.0.00 β Descriptior invalid (yes, that's the typo in the original, bestie π)APR::Const::POLLOUTβ since: 2.0.00 β Can write without blockingAPR::Const::POLLPRIβ since: 2.0.00 β Priority data available
:read_type πΈ
use APR::Const -compile => qw(:read_type);
The :read_type group is for IO constants. (periodt)
APR::Const::BLOCK_READβ since: 2.0.00 β the read function blocksAPR::Const::NONBLOCK_READβ since: 2.0.00 β the read function does not block
:shutdown_how π
use APR::Const -compile => qw(:shutdown_how);
The :shutdown_how group is for XXX constants. (not me writing XXX in the docs, but go off π)
APR::Const::SHUTDOWN_READβ since: 2.0.00APR::Const::SHUTDOWN_READWRITEβ since: 2.0.00APR::Const::SHUTDOWN_WRITEβ since: 2.0.00
:socket π
use APR::Const -compile => qw(:socket);
The :socket group is for the APR::Socket object constants, in methods opt_get and opt_set.
The following section discusses in detail each of the :socket constants. (get ready, bestie)
APR::Const::SO_DEBUG- Possible values:
XXX - since: 2.0.00
- Turns on debugging information
- Possible values:
APR::Const::SO_DISCONNECTED- Queries the disconnected state of the socket. (Currently only used on Windows)
- Possible values:
XXX - since: 2.0.00
APR::Const::SO_KEEPALIVE- Keeps connections active
- Possible values:
XXX - since: 2.0.00
APR::Const::SO_LINGER- Lingers on close if data is present
- since: 2.0.00
APR::Const::SO_NONBLOCK- Turns blocking IO mode on/off for socket.
- Possible values:
1 nonblocking
0 blocking
- For example, to set a socket to a blocking IO mode:
use APR::Socket ();
use APR::Const -compile => qw(SO_NONBLOCK);
...
if ($socket->opt_get(APR::Const::SO_NONBLOCK)) {
$socket->opt_set(APR::Const::SO_NONBLOCK => 0);
}
- You don't have to query for this option, before setting it. It was done for the demonstration purpose.
- since: 2.0.00
APR::Const::SO_RCVBUF- Controls the
ReceiveBufferSizesetting - Possible values:
XXX - since: 2.0.00
- Controls the
APR::Const::SO_REUSEADDR- The rules used in validating addresses supplied to bind should allow reuse of local addresses.
- Possible values:
XXX - since: 2.0.00
APR::Const::SO_SNDBUF- Controls the
SendBufferSizesetting - Possible values:
XXX - since: 2.0.00
- Controls the
:status π
use APR::Const -compile => qw(:status);
The :status group is for the API that return status code, or set the error variable XXXXXX. (yes, literally XXXXXX, no cap)
The following section discusses in detail each of the available :status constants.
APR::Const::TIMEUP- The operation did not finish before the timeout.
- since: 2.0.00
- Due to possible variants in conditions matching
TIMEUP, for checking error codes against this you most likely want to use theAPR::Status::is_TIMEUPfunction instead. (pro tip, bestie)
:table π
use APR::Const -compile => qw(:table);
The :table group is for overlap() and compress() constants. See APR::Table for details.
APR::Const::OVERLAP_TABLES_MERGEβ since: 2.0.00 β SeeAPR::Table::compressandAPR::Table::overlap.APR::Const::OVERLAP_TABLES_SETβ since: 2.0.00 β SeeAPR::Table::compressandAPR::Table::overlap.
:uri π
use APR::Const -compile => qw(:uri);
The :uri group of constants is for manipulating URIs. (we love a good URI manipulation era)
APR::Const::URI_ACAP_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_FTP_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_GOPHER_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_HTTPS_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_HTTP_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_IMAP_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_LDAP_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_NFS_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_NNTP_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_POP_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_PROSPERO_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_RTSP_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_SIP_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_SNEWS_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_SSH_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_TELNET_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_TIP_DEFAULT_PORTβ since: 2.0.00APR::Const::URI_UNP_OMITPASSWORDβ since: 2.0.00 β SeeAPR::URI::unparse.APR::Const::URI_UNP_OMITPATHINFOβ since: 2.0.00 β SeeAPR::URI::unparse.APR::Const::URI_UNP_OMITQUERYβ since: 2.0.00 β SeeAPR::URI::unparse.APR::Const::URI_UNP_OMITSITEPARTβ since: 2.0.00 β SeeAPR::URI::unparse.APR::Const::URI_UNP_OMITUSERβ since: 2.0.00 β SeeAPR::URI::unparse.APR::Const::URI_UNP_OMITUSERINFOβ since: 2.0.00APR::Const::URI_UNP_REVEALPASSWORDβ since: 2.0.00 β SeeAPR::URI::unparse.APR::Const::URI_WAIS_DEFAULT_PORTβ since: 2.0.00
Other Constants π
APR::PerlIO::PERLIO_LAYERS_ARE_ENABLEDβ since: 2.0.00 β See"APR::PerlIO::Constants")(yes, with the stray closing paren, iconic π)
See Also π
mod_perl 2.0 documentation.
Copyright π
mod_perl 2.0 and its core modules are copyrighted under The Apache Software License, Version 2.0.
Authors βοΈ
The mod_perl development team and numerous contributors.
π And that's a wrap, bestie! This iconic page is from perl v5.42.3, dated 2023-10-21, and it's docs::a...R::Const(3). Now go forth and constant-slaying! β¨π
π¦ where this page comes from
- nixos 26.05: mod_perl 2.0.13
- nixpkgs unstable: mod_perl 2.0.13
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms