mod_perl logo perl icon
previous page: APR::BucketType - Perl API for APR bucket typespage up: mod_perl 2.0 APInext page: APR::Date - Perl API for APR date manipulating functions

APR::Const - Perl Interface for APR Constants






mod_perl Pocket Reference

mod_perl Pocket Reference

By Andrew Ford
Writing Apache Modules with Perl and C

Writing Apache Modules with Perl and C

By Lincoln Stein, Doug MacEachern
Embedding Perl in HTML with Mason

Embedding Perl in HTML with Mason

By Dave Rolsky, Ken Williams
mod_perl2 User's Guide

mod_perl2 User's Guide

By Stas Bekman, Jim Brandt
Practical mod_perl

Practical mod_perl

By Stas Bekman, Eric Cholet
The mod_perl Developer's Cookbook

The mod_perl Developer's Cookbook

By Geoffrey Young, Paul Lindner, Randy Kobes


Table of Contents

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 ...);


TOP

Description

This package contains constants specific to APR features.

Refer to the Apache2::Const description section for more information.



TOP

Constants



TOP

:common

  use APR::Const -compile => qw(:common);

The :common group is for XXX constants.



TOP

APR::Const::SUCCESS



TOP

:error

  use APR::Const -compile => qw(:error);

The :error group is for XXX constants.



TOP

APR::Const::EABOVEROOT



TOP

APR::Const::EABSOLUTE



TOP

APR::Const::EACCES

Due to possible variants in conditions matching EACCES, for checking error codes against this you most likely want to use the APR::Status::is_EACCES function instead.



TOP

APR::Const::EAGAIN

The error Resource temporarily unavailable, may be returned by many different system calls, especially IO calls. Most likely you want to use the APR::Status::is_EAGAIN function instead.



TOP

APR::Const::EBADDATE



TOP

APR::Const::EBADF



TOP

APR::Const::EBADIP



TOP

APR::Const::EBADMASK



TOP

APR::Const::EBADPATH



TOP

APR::Const::EBUSY



TOP

APR::Const::ECONNABORTED

Due to possible variants in conditions matching ECONNABORTED, for checking error codes against this you most likely want to use the APR::Status::is_ECONNABORTED function instead.



TOP

APR::Const::ECONNREFUSED



TOP

APR::Const::ECONNRESET

Due to possible variants in conditions matching ECONNRESET, for checking error codes against this you most likely want to use the APR::Status::is_ECONNRESET function instead.



TOP

APR::Const::EDSOOPEN



TOP

APR::Const::EEXIST



TOP

APR::Const::EFTYPE



TOP

APR::Const::EGENERAL



TOP

APR::Const::EHOSTUNREACH



TOP

APR::Const::EINCOMPLETE



TOP

APR::Const::EINIT



TOP

APR::Const::EINPROGRESS



TOP

APR::Const::EINTR



TOP

APR::Const::EINVAL



TOP

APR::Const::EINVALSOCK



TOP

APR::Const::EMFILE



TOP

APR::Const::EMISMATCH



TOP

APR::Const::ENAMETOOLONG



TOP

APR::Const::END



TOP

APR::Const::ENETUNREACH



TOP

APR::Const::ENFILE



TOP

APR::Const::ENODIR



TOP

APR::Const::ENOENT

Due to possible variants in conditions matching ENOENT, for checking error codes against this you most likely want to use the APR::Status::is_ENOENT function instead.



TOP

APR::Const::ENOLOCK



TOP

APR::Const::ENOMEM



TOP

APR::Const::ENOPOLL



TOP

APR::Const::ENOPOOL



TOP

APR::Const::ENOPROC



TOP

APR::Const::ENOSHMAVAIL



TOP

APR::Const::ENOSOCKET



TOP

APR::Const::ENOSPC



TOP

APR::Const::ENOSTAT



TOP

APR::Const::ENOTDIR



TOP

APR::Const::ENOTEMPTY



TOP

APR::Const::ENOTHDKEY



TOP

APR::Const::ENOTHREAD



TOP

APR::Const::ENOTIME



TOP

APR::Const::ENOTIMPL

Something is not implemented



TOP

APR::Const::ENOTSOCK



TOP

APR::Const::EOF

Due to possible variants in conditions matching EOF, for checking error codes against this you most likely want to use the APR::Status::is_EOF function instead.



TOP

APR::Const::EPATHWILD



TOP

APR::Const::EPIPE



TOP

APR::Const::EPROC_UNKNOWN



TOP

APR::Const::ERELATIVE



TOP

APR::Const::ESPIPE



TOP

APR::Const::ESYMNOTFOUND



TOP

APR::Const::ETIMEDOUT



TOP

APR::Const::EXDEV



TOP

:fopen

  use APR::Const -compile => qw(:fopen);

The :fopen group is for XXX constants.



TOP

APR::Const::FOPEN_BINARY



TOP

APR::Const::FOPEN_BUFFERED



TOP

APR::Const::FOPEN_CREATE



TOP

APR::Const::FOPEN_DELONCLOSE



TOP

APR::Const::FOPEN_EXCL



TOP

APR::Const::FOPEN_PEND



TOP

APR::Const::FOPEN_READ



TOP

APR::Const::FOPEN_TRUNCATE



TOP

APR::Const::FOPEN_WRITE



TOP

:filepath

  use APR::Const -compile => qw(:filepath);

The :filepath group is for XXX constants.



TOP

APR::Const::FILEPATH_ENCODING_LOCALE



TOP

APR::Const::FILEPATH_ENCODING_UNKNOWN



TOP

APR::Const::FILEPATH_ENCODING_UTF8



TOP

APR::Const::FILEPATH_NATIVE



TOP

APR::Const::FILEPATH_NOTABOVEROOT



TOP

APR::Const::FILEPATH_NOTABSOLUTE



TOP

APR::Const::FILEPATH_NOTRELATIVE



TOP

APR::Const::FILEPATH_SECUREROOT



TOP

APR::Const::FILEPATH_SECUREROOTTEST



TOP

APR::Const::FILEPATH_TRUENAME



TOP

:fprot

  use APR::Const -compile => qw(:fprot);

The :fprot group is used by $finfo->protection.



TOP

APR::Const::FPROT_GEXECUTE

Execute by group



TOP

APR::Const::FPROT_GREAD

Read by group



TOP

APR::Const::FPROT_GSETID

Set group id



TOP

APR::Const::FPROT_GWRITE

Write by group



TOP

APR::Const::FPROT_OS_DEFAULT

use OS's default permissions



TOP

APR::Const::FPROT_UEXECUTE

Execute by user



TOP

APR::Const::FPROT_UREAD

Read by user



TOP

APR::Const::FPROT_USETID

Set user id



TOP

APR::Const::FPROT_UWRITE

Write by user



TOP

APR::Const::FPROT_WEXECUTE

Execute by others



TOP

APR::Const::FPROT_WREAD

Read by others



TOP

APR::Const::FPROT_WSTICKY

Sticky bit



TOP

APR::Const::FPROT_WWRITE

Write by others



TOP

:filetype

  use APR::Const -compile => qw(:filetype);

The :filetype group is used by $finfo->filetype.



TOP

APR::Const::FILETYPE_BLK

a file is a block device



TOP

APR::Const::FILETYPE_CHR

a file is a character device



TOP

APR::Const::FILETYPE_DIR

a file is a directory



TOP

APR::Const::FILETYPE_LNK

a file is a symbolic link



TOP

APR::Const::FILETYPE_NOFILE

the file type is undedetermined.



TOP

APR::Const::FILETYPE_PIPE

a file is a FIFO or a pipe.



TOP

APR::Const::FILETYPE_REG

a file is a regular file.



TOP

APR::Const::FILETYPE_SOCK

a file is a [unix domain] socket.



TOP

APR::Const::FILETYPE_UNKFILE

a file is of some other unknown type or the type cannot be determined.



TOP

:finfo

  use APR::Const -compile => qw(:finfo);

The :finfo group is used by stat() and $finfo->valid.



TOP

APR::Const::FINFO_ATIME

Access Time



TOP

APR::Const::FINFO_CSIZE

Storage size consumed by the file



TOP

APR::Const::FINFO_CTIME

Creation Time



TOP

APR::Const::FINFO_DEV

Device



TOP

APR::Const::FINFO_DIRENT

an atomic unix apr_dir_read()



TOP

APR::Const::FINFO_GPROT

Group protection bits



TOP

APR::Const::FINFO_GROUP

Group id



TOP

APR::Const::FINFO_ICASE

whether device is case insensitive



TOP

APR::Const::FINFO_IDENT

device and inode



TOP

APR::Const::FINFO_INODE

Inode



TOP

APR::Const::FINFO_LINK

Stat the link not the file itself if it is a link



TOP

APR::Const::FINFO_MIN

type, mtime, ctime, atime, size



TOP

APR::Const::FINFO_MTIME

Modification Time



TOP

APR::Const::FINFO_NAME

name in proper case



TOP

APR::Const::FINFO_NLINK

Number of links



TOP

APR::Const::FINFO_NORM

All fields provided by an atomic unix apr_stat()



TOP

APR::Const::FINFO_OWNER

user and group



TOP

APR::Const::FINFO_PROT

all protections



TOP

APR::Const::FINFO_SIZE

Size of the file



TOP

APR::Const::FINFO_TYPE

Type



TOP

APR::Const::FINFO_UPROT

User protection bits



TOP

APR::Const::FINFO_USER

User id



TOP

APR::Const::FINFO_WPROT

World protection bits



TOP

:flock

  use APR::Const -compile => qw(:flock);

The :flock group is for XXX constants.



TOP

APR::Const::FLOCK_EXCLUSIVE



TOP

APR::Const::FLOCK_NONBLOCK



TOP

APR::Const::FLOCK_SHARED



TOP

APR::Const::FLOCK_TYPEMASK



TOP

:hook

  use APR::Const -compile => qw(:hook);

The :hook group is for XXX constants.



TOP

APR::Const::HOOK_FIRST



TOP

APR::Const::HOOK_LAST



TOP

APR::Const::HOOK_MIDDLE



TOP

APR::Const::HOOK_REALLY_FIRST



TOP

APR::Const::HOOK_REALLY_LAST



TOP

:limit

  use APR::Const -compile => qw(:limit);

The :limit group is for XXX constants.



TOP

APR::Const::LIMIT_CPU



TOP

APR::Const::LIMIT_MEM



TOP

APR::Const::LIMIT_NOFILE



TOP

APR::Const::LIMIT_NPROC



TOP

:lockmech

  use APR::Const -compile => qw(:lockmech);

The :lockmech group is for XXX constants.



TOP

APR::Const::LOCK_DEFAULT



TOP

APR::Const::LOCK_FCNTL



TOP

APR::Const::LOCK_FLOCK



TOP

APR::Const::LOCK_POSIXSEM



TOP

APR::Const::LOCK_PROC_PTHREAD



TOP

APR::Const::LOCK_SYSVSEM



TOP

:poll

  use APR::Const -compile => qw(:poll);

The :poll group is used by poll.



TOP

APR::Const::POLLERR

Pending error



TOP

APR::Const::POLLHUP

Hangup occurred



TOP

APR::Const::POLLIN

Can read without blocking



TOP

APR::Const::POLLNVAL

Descriptior invalid



TOP

APR::Const::POLLOUT

Can write without blocking



TOP

APR::Const::POLLPRI

Priority data available



TOP

:read_type

  use APR::Const -compile => qw(:read_type);

The :read_type group is for IO constants.



TOP

APR::Const::BLOCK_READ

the read function blocks



TOP

APR::Const::NONBLOCK_READ

the read function does not block



TOP

:shutdown_how

  use APR::Const -compile => qw(:shutdown_how);

The :shutdown_how group is for XXX constants.



TOP

APR::Const::SHUTDOWN_READ



TOP

APR::Const::SHUTDOWN_READWRITE



TOP

APR::Const::SHUTDOWN_WRITE



TOP

: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.



TOP

APR::Const::SO_DEBUG

Possible values:

XXX

Turns on debugging information



TOP

APR::Const::SO_DISCONNECTED

Queries the disconnected state of the socket. (Currently only used on Windows)

Possible values:

XXX



TOP

APR::Const::SO_KEEPALIVE

Keeps connections active

Possible values:

XXX



TOP

APR::Const::SO_LINGER

Lingers on close if data is present



TOP

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.



TOP

APR::Const::SO_RCVBUF

Controls the ReceiveBufferSize setting

Possible values:

XXX



TOP

APR::Const::SO_REUSEADDR

The rules used in validating addresses supplied to bind should allow reuse of local addresses.

Possible values:

XXX



TOP

APR::Const::SO_SNDBUF

Controls the SendBufferSize setting

Possible values:

XXX



TOP

:status

  use APR::Const -compile => qw(:status);

The :status group is for the API that return status code, or set the error variable XXXXXX.

The following section discusses in detail each of the available :status constants.



TOP

APR::Const::TIMEUP

The operation did not finish before the timeout.

Due to possible variants in conditions matching TIMEUP, for checking error codes against this you most likely want to use the APR::Status::is_TIMEUP function instead.



TOP

:table

  use APR::Const -compile => qw(:table);

The :table group is for overlap() and compress() constants. See APR::Table for details.



TOP

APR::Const::OVERLAP_TABLES_MERGE

See APR::Table::compress and APR::Table::overlap.



TOP

APR::Const::OVERLAP_TABLES_SET

See APR::Table::compress and APR::Table::overlap.



TOP

:uri

  use APR::Const -compile => qw(:uri);

The :uri group of constants is for manipulating URIs.



TOP

APR::Const::URI_ACAP_DEFAULT_PORT



TOP

APR::Const::URI_FTP_DEFAULT_PORT



TOP

APR::Const::URI_GOPHER_DEFAULT_PORT



TOP

APR::Const::URI_HTTPS_DEFAULT_PORT



TOP

APR::Const::URI_HTTP_DEFAULT_PORT



TOP

APR::Const::URI_IMAP_DEFAULT_PORT



TOP

APR::Const::URI_LDAP_DEFAULT_PORT



TOP

APR::Const::URI_NFS_DEFAULT_PORT



TOP

APR::Const::URI_NNTP_DEFAULT_PORT



TOP

APR::Const::URI_POP_DEFAULT_PORT



TOP

APR::Const::URI_PROSPERO_DEFAULT_PORT



TOP

APR::Const::URI_RTSP_DEFAULT_PORT



TOP

APR::Const::URI_SIP_DEFAULT_PORT



TOP

APR::Const::URI_SNEWS_DEFAULT_PORT



TOP

APR::Const::URI_SSH_DEFAULT_PORT



TOP

APR::Const::URI_TELNET_DEFAULT_PORT



TOP

APR::Const::URI_TIP_DEFAULT_PORT



TOP

APR::Const::URI_UNP_OMITPASSWORD

See APR::URI::unparse.



TOP

APR::Const::URI_UNP_OMITPATHINFO

See APR::URI::unparse.



TOP

APR::Const::URI_UNP_OMITQUERY

See APR::URI::unparse.



TOP

APR::Const::URI_UNP_OMITSITEPART

See APR::URI::unparse.



TOP

APR::Const::URI_UNP_OMITUSER

See APR::URI::unparse.



TOP

APR::Const::URI_UNP_OMITUSERINFO



TOP

APR::Const::URI_UNP_REVEALPASSWORD

See APR::URI::unparse.



TOP

APR::Const::URI_WAIS_DEFAULT_PORT



TOP

Other Constants



TOP

APR::PerlIO::PERLIO_LAYERS_ARE_ENABLED

See APR::PerlIO::Constants)



TOP

See Also

mod_perl 2.0 documentation.



TOP

Copyright

mod_perl 2.0 and its core modules are copyrighted under The Apache Software License, Version 2.0.



TOP

Authors

The mod_perl development team and numerous contributors.






TOP
previous page: APR::BucketType - Perl API for APR bucket typespage up: mod_perl 2.0 APInext page: APR::Date - Perl API for APR date manipulating functions