File_Fstab
[ class tree: File_Fstab ] [ index: File_Fstab ] [ all elements ]

Class: File_Fstab_Entry

Source Location: /File_Fstab-2.0.3/File/Fstab/Entry.php

Class Overview


A single entry in a fstab file


Author(s):

Version:

  • CVS: $Revision: 304144 $

Copyright:

  • (c) 2004, 2005 Ian Eure

Variables

Methods


Inherited Variables

Inherited Methods


Class Details

[line 46]
A single entry in a fstab file


[ Top ]


Class Variables

$device =  '/dev/null'

[line 62]

Block device

Only one of $device, $uuid, or $label will be set, based on what's in the fstab entry.


Type:   string


[ Top ]

$dumpFrequency =  0

[line 112]

Device dump frequency

Type:   int


[ Top ]

$entry =

[line 52]

Raw line from fstab

Type:   string


[ Top ]

$fsckPassNo =  0

[line 119]

Device fsck pass number

Type:   int


[ Top ]

$fsType =  'auto'

[line 96]

Device filesystem type

Type:   string


[ Top ]

$label =

[line 82]

Device label

Only one of $device, $uuid, or $label will be set, based on what's in the fstab entry.


Type:   string


[ Top ]

$mountOptions = array(
            'defaults' => "defaults"
    )

[line 103]

Mount options

Type:   array


[ Top ]

$mountPoint =  '/mnt'

[line 89]

Device mount point

Type:   string


[ Top ]

$uuid =

[line 72]

Device UUID

Only one of $device, $uuid, or $label will be set, based on what's in the fstab entry.


Type:   string


[ Top ]



Method Detail

File_Fstab_Entry (Constructor)   [line 136]

void File_Fstab_Entry( [string $entry = false])

Constructor

Parameters:

string   $entry   —  Single entry from fstab file

[ Top ]

getDevice   [line 167]

string getDevice( )

Get block device
  • Since: 2.0.0beta1

[ Top ]

getDeviceType   [line 502]

int getDeviceType( )

Get device type
  • Return: One of FILE_FSTAB_ENTRY_DEVTYPE_BLOCKDEV, _UUID, or _LABEL

[ Top ]

getDeviceUUIDOrLabel   [line 460]

string getDeviceUUIDOrLabel( )

Get device, or uuid, or label
  • Return: Device/UUID/LABEL

[ Top ]

getDumpFrequency   [line 295]

int getDumpFrequency( )

Get filesystem dump frequency
  • Since: 2.0.0beta1

[ Top ]

getEntry   [line 442]

string getEntry( $seperator)

Get the fstab entry

This rebuilds the entry from the class variables.

  • Return: The fstab entry

Parameters:

   $seperator   — 

[ Top ]

getFsckPassNo   [line 319]

int getFsckPassNo( )

Get filesystem fsck pass number
  • Since: 2.0.0beta1

[ Top ]

getFsType   [line 271]

string getFsType( )

Get filesystem type
  • Since: 2.0.0beta1

[ Top ]

getLabel   [line 223]

string getLabel( )

Get device label
  • Since: 2.0.0beta1

[ Top ]

getMountOption   [line 530]

string getMountOption( string $which)

Get a mount option
  • Return: Mount option

Parameters:

string   $which   —  Option to get

[ Top ]

getMountPoint   [line 247]

string getMountPoint( )

Get mount point
  • Since: 2.0.0beta1

[ Top ]

getUUID   [line 195]

string getUUID( )

Get UUID
  • Since: 2.0.0beta1

[ Top ]

hasMountOption   [line 519]

boolean hasMountOption( string $option)

Is an option set?

Parameters:

string   $option   —  Option name

[ Top ]

parse   [line 342]

mixed parse( string $entry)

Parse fstab entry
  • Return: true on success, PEAR_Error on failure

Parameters:

string   $entry   —  Line from fstab to parse

[ Top ]

setDevice   [line 154]

mixed setDevice( string $device)

Set block device

Only one of device, uuid, or label may be set; setting this will un-set any valies in the other variables.

  • Return: boolean true on success, PEAR_Error otherwise
  • Since: 2.0.0beta1

Parameters:

string   $device   —  Value to set

[ Top ]

setDumpFrequency   [line 283]

mixed setDumpFrequency( $freq, int $type)

Set filesystem dump frequency
  • Return: boolean true on success, PEAR_Error otherwise
  • Since: 2.0.0beta1

Parameters:

int   $type   —  Value to set
   $freq   — 

[ Top ]

setEntry   [line 330]

void setEntry( string $entry)

Set an entry

Parameters:

string   $entry   —  Single entry from fstab file

[ Top ]

setFsckPassNo   [line 307]

mixed setFsckPassNo( $pass, int $type)

Set filesystem fsck pass number
  • Return: boolean true on success, PEAR_Error otherwise
  • Since: 2.0.0beta1

Parameters:

int   $type   —  Value to set
   $pass   — 

[ Top ]

setFsType   [line 259]

mixed setFsType( string $type)

Set filesystem type
  • Return: boolean true on success, PEAR_Error otherwise
  • Since: 2.0.0beta1

Parameters:

string   $type   —  Value to set

[ Top ]

setLabel   [line 210]

mixed setLabel( string $label)

Set device label

Only one of device, uuid, or label may be set; setting this will un-set any valies in the other variables.

  • Return: boolean true on success, PEAR_Error otherwise
  • Since: 2.0.0beta1

Parameters:

string   $label   —  Value to set

[ Top ]

setMountOption   [line 545]

void setMountOption( string $name, [string $value = false])

Set a mount option

Parameters:

string   $name   —  Option to set
string   $value   —  Value to give option, or blank if option takes no args

[ Top ]

setMountPoint   [line 235]

mixed setMountPoint( string $dir)

Set mount point
  • Return: boolean true on success, PEAR_Error otherwise
  • Since: 2.0.0beta1

Parameters:

string   $dir   —  Value to set

[ Top ]

setUUID   [line 182]

mixed setUUID( string $uuid)

Set UUID

Only one of device, uuid, or label may be set; setting this will un-set any valies in the other variables.

  • Return: boolean true on success, PEAR_Error otherwise
  • Since: 2.0.0beta1

Parameters:

string   $uuid   —  Value to set

[ Top ]

_getDeviceEntry   [line 480]

string _getDeviceEntry( )

Get device entry for building fstab

This is like getDeviceUUIDOrLabel(), but we prefix the actual value with the necessary string for it to work in the fstab.

  • Return: Device/UUID/LABEL
  • Access: protected

[ Top ]

_makeMountOptions   [line 422]

string _makeMountOptions( )

Reconstruct fstab options from $mountOptions
  • Return: fstab mount options
  • Access: protected

[ Top ]

_parseMountOptions   [line 402]

void _parseMountOptions( $options $options)

Parse fstab options
  • Access: protected

Parameters:

$options   $options   —  string Mount options from fstab

[ Top ]


Documentation generated on Mon, 11 Mar 2019 15:39:47 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.