Google Shared Contacts Manager  1.0
Semestral project for BI-ZNF
APIQuery Class Reference

Class represents a query that is going to be send to Google. More...

Public Member Functions

 getHeaders ()
 
 setHeaders ($headers)
 
 getBody ()
 
 setBody ($body)
 
 getResponse ()
 
 setResponse ($response)
 
 getResponseCode ()
 
 setResponseCode ($responseCode)
 
 getTarget ()
 
 setTarget ($target)
 
 getMethod ()
 
 setMethod ($method)
 
 getExpectedResponseCode ()
 
 setExpectedResponseCode ($expectedResponseCode)
 
 getContentType ()
 
 setContentType ($contentType)
 

Data Fields

const HTTP_METHOD_POST = 'POST'
 
const HTTP_METHOD_GET = 'GET'
 
const HTTP_METHOD_DELETE = 'DELETE'
 
const HTTP_METHOD_PUT = 'PUT'
 
const HTTP_RESPONSE_OK = 200
 
const HTTP_RESPONSE_CREATED = 201
 
const HTTP_RESPONSE_NOT_FOUND = 404
 
const CONTENT_ATOM = "application/atom+xml"
 

Private Attributes

 $headers
 
 $body
 
 $response
 
 $responseCode
 
 $target
 
 $method
 
 $expectedResponseCode
 
 $contentType
 

Detailed Description

Class represents a query that is going to be send to Google.

It holds all important information to be able to contact Google API.

Member Function Documentation

◆ getBody()

getBody ( )
Returns
string

◆ getContentType()

getContentType ( )
Returns
string

◆ getExpectedResponseCode()

getExpectedResponseCode ( )
Returns
int

◆ getHeaders()

getHeaders ( )
Returns
string

◆ getMethod()

getMethod ( )
Returns
mixed

◆ getResponse()

getResponse ( )
Returns
string

◆ getResponseCode()

getResponseCode ( )
Returns
int

◆ getTarget()

getTarget ( )
Returns
string

◆ setBody()

setBody (   $body)
Parameters
string$body
Returns
APIQuery

◆ setContentType()

setContentType (   $contentType)
Parameters
string$contentType
Returns
APIQuery

◆ setExpectedResponseCode()

setExpectedResponseCode (   $expectedResponseCode)
Parameters
int$expectedResponseCode
Returns
APIQuery

◆ setHeaders()

setHeaders (   $headers)
Parameters
string$headers
Returns
APIQuery

◆ setMethod()

setMethod (   $method)
Parameters
mixed$method
Returns
APIQuery

◆ setResponse()

setResponse (   $response)
Parameters
string$response
Returns
APIQuery

◆ setResponseCode()

setResponseCode (   $responseCode)
Parameters
int$responseCode
Returns
APIQuery

◆ setTarget()

setTarget (   $target)
Parameters
string$target
Returns
APIQuery

Field Documentation

◆ $body

$body
private

◆ $contentType

$contentType
private

◆ $expectedResponseCode

$expectedResponseCode
private

◆ $headers

$headers
private

◆ $method

$method
private

◆ $response

$response
private

◆ $responseCode

$responseCode
private

◆ $target

$target
private

◆ CONTENT_ATOM

const CONTENT_ATOM = "application/atom+xml"

◆ HTTP_METHOD_DELETE

const HTTP_METHOD_DELETE = 'DELETE'

◆ HTTP_METHOD_GET

const HTTP_METHOD_GET = 'GET'

◆ HTTP_METHOD_POST

const HTTP_METHOD_POST = 'POST'

◆ HTTP_METHOD_PUT

const HTTP_METHOD_PUT = 'PUT'

◆ HTTP_RESPONSE_CREATED

const HTTP_RESPONSE_CREATED = 201

◆ HTTP_RESPONSE_NOT_FOUND

const HTTP_RESPONSE_NOT_FOUND = 404

◆ HTTP_RESPONSE_OK

const HTTP_RESPONSE_OK = 200

The documentation for this class was generated from the following file: