Sophie

Sophie

distrib > Mageia > 4 > x86_64 > by-pkgid > 2caf8180cdd72937109cd6eb1711fd28 > files > 142

php-pear-PhpDocumentor-1.4.4-3.1.mga4.noarch.rpm

<refentry id="{@id}">
 <refnamediv>
  <refname>@access</refname>
  <refpurpose>Access control for an element.  @access private prevents documentation of the following element (if enabled).</refpurpose>
 </refnamediv>
 <refsynopsisdiv>
  <refsynopsisdivinfo>
   <author>
    Gregory Beaver
    <authorblurb>Tag Documentation written by {@link mailto:cellog@php.net cellog@php.net}</authorblurb>
   </author>
   <copyright>Copyright 2002, Gregory Beaver</copyright>
   <releaseinfo>phpDocumentor 0.1+</releaseinfo>
  </refsynopsisdivinfo>
  <cmdsynopsis>
   <command>@access</command>
   <arg choice="req">
    <group>
     <arg>private</arg>
     <arg>protected</arg>
     <arg>public</arg>
    </group>
   </arg>
  </cmdsynopsis>
 </refsynopsisdiv>
 <refsect1 id="{@id description}">
  <title>Description</title>
  <para>@access controls phpDocumentor's documentation of an element.</para>
  <para>If @access is private, the element will not be documented unless specified by command-line switch --parseprivate.</para>
 </refsect1>
 <refsect1 id="{@id example}">
  <title>Example</title>
  <para>
   <programlisting role="php">
   <![CDATA[
/**
 * function func1, public access is assumed
 */
function func1()
{
}

/**
 * function func2, access is private, will not be documented
 * @access private
 */
function func2()
{
}

/**
 * This is possible, but redundant.  An element has @access public by default
 * @access public
 */
class class1
{
   /**
    * all text in this DocBlock will be ignored, unless command-line switch or
    * setting in a user INI file enables documenting of private elements
    * @access private
    */
   var $private_var;
   /**
    * Protected is allowed, but does absolutely nothing.  Use it to inform users
    * that an element should only be referenced by this and child classes,
    * and not directly
    * @access protected
    */
   
   /**
    * this function is documented
    */
   function publicmethod()
   {
   }
}
   ]]>
   </programlisting>
  </para>
 </refsect1>
</refentry>