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

Class: XML_RPC2_Backend_Php_Value_Datetime

Source Location: /XML_RPC2-1.1.2/XML/RPC2/Backend/Php/Value/Datetime.php

Class Overview

XML_RPC2_Value
   |
   --XML_RPC2_Backend_Php_Value
      |
      --XML_RPC2_Backend_Php_Value_Datetime

XML_RPC datetime value class. Instances of this class represent datetime scalars in XML_RPC


Author(s):

Copyright:

  • 2004-2006 Sergio Carvalho

Methods


Inherited Variables

Inherited Methods

Class: XML_RPC2_Backend_Php_Value

XML_RPC2_Backend_Php_Value::createFromDecode()
Decode an encoded value and build the applicable XML_RPC2_Value subclass
XML_RPC2_Backend_Php_Value::createFromNative()
Choose a XML_RPC2_Value subclass appropriate for the given value and create it.
XML_RPC2_Backend_Php_Value::getNativeValue()
nativeValue property getter
XML_RPC2_Backend_Php_Value::setNativeValue()
nativeValue setter

Class: XML_RPC2_Value

XML_RPC2_Value::createFromNative()
Factory method that constructs the appropriate XML-RPC encoded type value

Class Details

[line 65]
XML_RPC datetime value class. Instances of this class represent datetime scalars in XML_RPC

To work on a compatible way with the xmlrpcext backend, we introduce a particular "nativeValue" which is a standard class (stdclass) with three public properties : scalar => the iso8601 date string timestamp => the corresponding timestamp (int) xmlrpc_type => 'datetime'

The constructor can be called with a iso8601 string, with a timestamp or with a such object



[ Top ]


Method Detail

__construct (Constructor)   [line 79]

XML_RPC2_Backend_Php_Value_Datetime __construct( mixed $nativeValue)

Constructor. Will build a new XML_RPC2_Backend_Php_Value_Datetime with the given value

The provided value can be an int, which will be interpreted as a Unix timestamp, or a string in iso8601 format, or a "stdclass native value"


Parameters:

mixed   $nativeValue   —  a timestamp, an iso8601 date or a "stdclass native value"

[ Top ]

decode   [line 174]

void decode( mixed $xml)

Decode transport XML and set the instance value accordingly
  • Access: public

Parameters:

mixed   $xml   —  The encoded XML-RPC value,

[ Top ]

encode   [line 199]

string encode( )

Encode the instance into XML, for transport
  • Return: The encoded XML-RPC value,
  • Access: public

[ Top ]


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