コード例 #1
0
 public static function GetObjectFromSoapObject($objSoapObject)
 {
     $objToReturn = new WikiVersion();
     if (property_exists($objSoapObject, 'Id')) {
         $objToReturn->intId = $objSoapObject->Id;
     }
     if (property_exists($objSoapObject, 'WikiItem') && $objSoapObject->WikiItem) {
         $objToReturn->WikiItem = WikiItem::GetObjectFromSoapObject($objSoapObject->WikiItem);
     }
     if (property_exists($objSoapObject, 'VersionNumber')) {
         $objToReturn->intVersionNumber = $objSoapObject->VersionNumber;
     }
     if (property_exists($objSoapObject, 'Name')) {
         $objToReturn->strName = $objSoapObject->Name;
     }
     if (property_exists($objSoapObject, 'PostedByPerson') && $objSoapObject->PostedByPerson) {
         $objToReturn->PostedByPerson = Person::GetObjectFromSoapObject($objSoapObject->PostedByPerson);
     }
     if (property_exists($objSoapObject, 'PostDate')) {
         $objToReturn->dttPostDate = new QDateTime($objSoapObject->PostDate);
     }
     if (property_exists($objSoapObject, '__blnRestored')) {
         $objToReturn->__blnRestored = $objSoapObject->__blnRestored;
     }
     return $objToReturn;
 }
コード例 #2
0
 public static function GetArrayFromSoapArray($objSoapArray)
 {
     $objArrayToReturn = array();
     foreach ($objSoapArray as $objSoapObject) {
         array_push($objArrayToReturn, WikiItem::GetObjectFromSoapObject($objSoapObject));
     }
     return $objArrayToReturn;
 }
コード例 #3
0
 public static function GetObjectFromSoapObject($objSoapObject)
 {
     $objToReturn = new TopicLink();
     if (property_exists($objSoapObject, 'Id')) {
         $objToReturn->intId = $objSoapObject->Id;
     }
     if (property_exists($objSoapObject, 'TopicLinkTypeId')) {
         $objToReturn->intTopicLinkTypeId = $objSoapObject->TopicLinkTypeId;
     }
     if (property_exists($objSoapObject, 'TopicCount')) {
         $objToReturn->intTopicCount = $objSoapObject->TopicCount;
     }
     if (property_exists($objSoapObject, 'MessageCount')) {
         $objToReturn->intMessageCount = $objSoapObject->MessageCount;
     }
     if (property_exists($objSoapObject, 'LastPostDate')) {
         $objToReturn->dttLastPostDate = new QDateTime($objSoapObject->LastPostDate);
     }
     if (property_exists($objSoapObject, 'Forum') && $objSoapObject->Forum) {
         $objToReturn->Forum = Forum::GetObjectFromSoapObject($objSoapObject->Forum);
     }
     if (property_exists($objSoapObject, 'Issue') && $objSoapObject->Issue) {
         $objToReturn->Issue = Issue::GetObjectFromSoapObject($objSoapObject->Issue);
     }
     if (property_exists($objSoapObject, 'WikiItem') && $objSoapObject->WikiItem) {
         $objToReturn->WikiItem = WikiItem::GetObjectFromSoapObject($objSoapObject->WikiItem);
     }
     if (property_exists($objSoapObject, 'Package') && $objSoapObject->Package) {
         $objToReturn->Package = Package::GetObjectFromSoapObject($objSoapObject->Package);
     }
     if (property_exists($objSoapObject, '__blnRestored')) {
         $objToReturn->__blnRestored = $objSoapObject->__blnRestored;
     }
     return $objToReturn;
 }