Cisco Cisco Prime Network Registrar 8.1 Technical References

Page of 316
getBlock 
Cisco Prime Network Registrar IPAM 8.1.1 CLI and API Guide 
     211 
getBlock 
There are two calls to retrieve blocks: 
•  getBlockByName 
•  getBlockByIpAddress 
Both calls return a 
WSGenericBlock
 data structure.  See the 
ModifyBlock
 call (Page 
186) for a description of 
WSGenericBlock
.  As their names suggest, they differ in how 
the block is located. 
Use one of the above calls in conjunction with the 
ModifyBlock
 call to update an 
existing block.  Modify the returned structure as needed and pass the modified structure to 
ModifyBlock
. Note that the complete container path will be returned in the 
WSGenericBlock
Request and Response Messages 
Below is the portion of 
Gets.wsdl that describes the 
getBlockByName
 and 
getBlockByIpAddress
 request and response messages. 
<wsdl:message name="getBlockByNameRequest"> 
   <wsdl:part name="name" type="soapenc:string"/> 
   <wsdl:part name="container" type="soapenc:string"/> 
</wsdl:message> 
<wsdl:message name="getBlockByNameResponse"> 
   <wsdl:part name="getBlockByNameReturn" type="tns2:WSGenericBlock"/> 
</wsdl:message> 
 
<wsdl:message name="getBlockByIpAddressRequest"> 
   <wsdl:part name="ipAddress" type="soapenc:string"/> 
   <wsdl:part name="container" type="soapenc:string"/> 
   <wsdl:part name="size" type="xsd:int"/> 
   <wsdl:part name="status" type="soapenc:string"/> 
</wsdl:message> 
<wsdl:message name="getBlockByIpAddressResponse"> 
   <wsdl:part name="getBlockByIpAddressReturn" type="tns2:WSGenericBlock"/> 
</wsdl:message> 
Response 
If the block is found, a 
WSGenericBlock
 structure is filled in with its information.  See 
the 
ModifyBlock
 API call for more information.  
getBlockByName Request 
This request has two parameters. 
Parameter Name 
Description 
Required 
Name 
The Name of the block, e.g. 10.0.0.0/24 
Yes 
Container 
The container holding the block. 
Only if name is not 
unique.