Skip to content
This repository has been archived by the owner on Jan 10, 2024. It is now read-only.

Commit

Permalink
Added update() method
Browse files Browse the repository at this point in the history
  • Loading branch information
Pat Patterson committed Nov 8, 2011
1 parent 45fe065 commit 2f4b1f3
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions soapclient/SforceMetadataClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,14 @@ public function create($obj) {
return $this->sforce->create($encodedObj);
}

public function update($obj) {
$encodedObj = new stdClass();
$encodedObj->UpdateMetadata = $obj;
$encodedObj->UpdateMetadata->metadata = new SoapVar($obj->metadata, SOAP_ENC_OBJECT, $this->getObjtype($obj->metadata), $this->namespace);

return $this->sforce->update($encodedObj);
}

public function delete($obj) {
$encodedObj = new stdClass();
$encodedObj->metadata = new SoapVar($obj, SOAP_ENC_OBJECT, $this->getObjtype($obj), $this->namespace);
Expand Down

0 comments on commit 2f4b1f3

Please sign in to comment.