Skip to content

Commit

Permalink
Merge pull request #231 from jamesiarmes/issue-86-missing-types
Browse files Browse the repository at this point in the history
Closes #86, Closes #87: Added missing types and updated documentation.
  • Loading branch information
jamesiarmes committed Dec 19, 2014
2 parents edbcb65 + e853d8e commit 730b4a1
Show file tree
Hide file tree
Showing 613 changed files with 39,626 additions and 4,265 deletions.
39 changes: 19 additions & 20 deletions EWSAutodiscover.php
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
<?php
/**
* Exchange Web Services Autodiscover implementation.
*
* @package php-ews
* @subpackage Auto Discovery
* Contains EWSAutodiscover.
*/

/**
* Exchange Web Services Autodiscover implementation
*
* This class supports POX (Plain Old XML), which is deprecated but functional
* in Exchange 2010. It may make sense for you to combine your Autodiscovery
* in Exchange 2010. It may make sense for you to combine your Autodiscovery
* efforts with a SOAP Autodiscover request as well.
*
* USAGE:
Expand All @@ -30,6 +27,8 @@
*
* @link http://technet.microsoft.com/en-us/library/bb332063(EXCHG.80).aspx
* @link https://www.testexchangeconnectivity.com/
*
* @package php-ews\AutoDiscovery
*/
class EWSAutodiscover
{
Expand Down Expand Up @@ -136,15 +135,15 @@ class EWSAutodiscover

/**
* Skip SSL verification. Bad idea, and violates the strict Autodiscover
* protocol. But, here in case you have no other option.
* protocol. But, here in case you have no other option.
* Defaults to FALSE.
*
* @var boolean
*/
protected $skip_ssl_verification = false;

/**
* An associative array of response headers that resulted from the
* An associative array of response headers that resulted from the
* last request. Keys are lowercased for easy checking.
*
* @var array
Expand All @@ -166,7 +165,7 @@ class EWSAutodiscover
public $last_curl_errno;

/**
* Human-readable description of the most recent cURL error.
* Human-readable description of the most recent cURL error.
*
* @var string
*/
Expand All @@ -182,15 +181,15 @@ class EWSAutodiscover
public $connection_timeout = 2;

/**
* Information about an Autodiscover Response containing an error will
* Information about an Autodiscover Response containing an error will
* be stored here.
*
* @var mixed
*/
public $error = false;

/**
* Information about an Autodiscover Response with a redirect will be
* Information about an Autodiscover Response with a redirect will be
* retained here.
*
* @var mixed
Expand All @@ -206,7 +205,7 @@ class EWSAutodiscover
public $discovered = null;

/**
* Constructor for the EWSAutodiscover class.
* Constructor for the EWSAutodiscover class.
*
* @param string $email
* @param string $password
Expand Down Expand Up @@ -254,7 +253,7 @@ public function discover()
* Return the settings discovered from the Autodiscover process.
*
* NULL indicates discovery hasn't completed (or been attempted)
* FALSE indicates discovery wasn't successful. Check for errors
* FALSE indicates discovery wasn't successful. Check for errors
* or redirects.
* An array will be returned with discovered settings on success.
*
Expand Down Expand Up @@ -408,9 +407,9 @@ public static function getEWS($email, $password, $username = null)
return $auto->newEWS();
}

/**
* Perform an NTLM authenticated HTTPS POST to the top-level
* domain of the email address.
/**
* Perform an NTLM authenticated HTTPS POST to the top-level
* domain of the email address.
*
* @return An AUTODISCOVERED_VIA_* constant or FALSE on failure.
*/
Expand All @@ -426,7 +425,7 @@ public function tryTLD()
}

/**
* Perform an NTLM authenticated HTTPS POST to the 'autodiscover'
* Perform an NTLM authenticated HTTPS POST to the 'autodiscover'
* subdomain of the email address' TLD.
*
* @return An AUTODISCOVERED_VIA_* constant or FALSE on failure.
Expand Down Expand Up @@ -528,7 +527,7 @@ public function setCAInfo($path)
/**
* Set the path to the file to be used by CURLOPT_CAPATH.
*
* @param string $path Path to a directory containing one or more CA
* @param string $path Path to a directory containing one or more CA
* certificates.
* @return self
*/
Expand Down Expand Up @@ -616,7 +615,7 @@ public function doNTLMPost($url, $timeout = 6)
}

/**
* Parse the Autoresponse Payload, particularly to determine if an
* Parse the Autoresponse Payload, particularly to determine if an
* additional request is necessary.
*
* @return mixed FALSE if response isn't XML or parsed response array
Expand Down Expand Up @@ -674,7 +673,7 @@ protected function setTLD()
}

/**
* Reset the response-related structures. Called before making a new
* Reset the response-related structures. Called before making a new
* request.
*
* @return self
Expand Down Expand Up @@ -760,7 +759,7 @@ public function responseToArray($xml)
}

/**
* Recursive method for parsing DOM nodes.
* Recursive method for parsing DOM nodes.
*
* @link https://github.com/gaarf/XML-string-to-PHP-array
* @param object $node DOMNode object
Expand Down
9 changes: 4 additions & 5 deletions EWSType.php
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
<?php
/**
* Base class for Exchange Web Service Types
*
* @package php-ews
* @subpackage Types
* Contains EWSType.
*/

/**
* Base class for Exchange Web Service Types
* Base class for Exchange Web Service Types.
*
* @package php-ews\Types
*/
abstract class EWSType
{
Expand Down
31 changes: 18 additions & 13 deletions EWSType/AbsoluteDateTransitionType.php
Original file line number Diff line number Diff line change
@@ -1,29 +1,34 @@
<?php
/**
* The AbsoluteDateTransition element represents a time zone transition that
* occurs on a specific date and at a specific time.
*
* @package php-ews
* @subpackage Types
* Contains EWSType_AbsoluteDateTransitionType.
*/

/**
* Definition of the AbsoluteDateTransitionType type.
* Represents a time zone transition that occurs on a specific date and at a
* specific time.
*
* @package php-ews\Types
*/
class EWSType_AbsoluteDateTransitionType extends EWSType
{
/**
* Specifies the Period or TransitionsGroup that is the target of the time
* zone transition.
* Represents the date and time at which the time zone transition occurs.
*
* @var EWSType_TransitionTargetType
* @since Exchange 2010
*
* @var string
*
* @todo Make a DateTime object.
*/
public $To;
public $DateTime;

/**
* Represents the date and time at which the time zone transition occurs.
* Specifies the Period or TransitionsGroup that is the target of the time
* zone transition.
*
* @var string
* @since Exchange 2010
*
* @var EWSType_TransitionTargetType
*/
public $DateTime;
public $To;
}
31 changes: 25 additions & 6 deletions EWSType/AbsoluteMonthlyRecurrencePatternType.php
Original file line number Diff line number Diff line change
@@ -1,20 +1,39 @@
<?php
/**
* Definition of the AbsoluteMonthlyRecurrencePatternType type
*
* @package php-ews
* @subpackage Types
* Contains EWSType_AbsoluteMonthlyRecurrencePatternType.
*/

/**
* Definition of the AbsoluteMonthlyRecurrencePatternType type
* Represents a monthly recurrence pattern.
*
* @package php-ews\Types
*
* @todo Extend EWSType_IntervalRecurrencePatternBaseType.
*/
class EWSType_AbsoluteMonthlyRecurrencePatternType extends EWSType
{
/**
* DayOfMonth property
* Describes the day in a month that a recurring item occurs.
*
* The range of values for this property is 1 to 31. If for a particular
* month this value is larger than the number of days in the month, the last
* day of the month is assumed for this property.
*
* @since Exchange 2007
*
* @var integer
*/
public $DayOfMonth;

/**
* Defines the interval between two consecutive recurring items.
*
* For example, if the Interval has a value of 5, the recurring item occurs
* every five months. The range of valid values is from 1 to 99.
*
* @since Exchange 2007
*
* @var integer
*/
public $Interval;
}
23 changes: 16 additions & 7 deletions EWSType/AbsoluteYearlyRecurrencePatternType.php
Original file line number Diff line number Diff line change
@@ -1,25 +1,34 @@
<?php
/**
* Definition of the AbsoluteYearlyRecurrencePatternType type
*
* @package php-ews
* @subpackage Types
* Contains EWSType_AbsoluteYearlyRecurrencePatternType.
*/

/**
* Definition of the AbsoluteYearlyRecurrencePatternType type
* Represents a yearly recurrence pattern.
*
* @package php-ews\Types
*
* @todo Extend EWSTYpe_RecurrencePatternBaseType.
*/
class EWSType_AbsoluteYearlyRecurrencePatternType extends EWSType
{
/**
* DayOfMonth property
* Describes the day in a month on which a recurring item occurs.
*
* The range of values for this property is 1 to 31. If for a particular
* month this value is larger than the number of days in the month, the last
* day of the month is assumed for this property.
*
* @since Exchange 2007
*
* @var integer
*/
public $DayOfMonth;

/**
* Month property
* Describes the month in which a yearly recurring item occurs.
*
* @since Exchange 2007
*
* @var EWSType_MonthNamesType
*/
Expand Down
Loading

0 comments on commit 730b4a1

Please sign in to comment.