Packagecom.google.analytics.data
Classpublic class UTMCookie
ImplementsCookie
SubclassesUTMA, UTMB, UTMC, UTMK, UTMV, UTMX, UTMZ

The Urchin Tracking Module base cookie. note: all utmcookies should be able to - serialize/deserialize to SharedObject - keep the field sort order in serrialization ex: if utma cookie serialize to __utma=..... then domainHash should have field index 0, sessionId field index 1, etc. - each cookie should be able to notify a parent proxy when one of their field is updated



Public Properties
 PropertyDefined by
  creation : Date
The cookie creation date
UTMCookie
  expiration : Date
The cookie expiration date.
UTMCookie
  proxy : Buffer
UTMCookie
Protected Properties
 PropertyDefined by
  fields : Array
UTMCookie
  inURL : String
UTMCookie
  name : String
UTMCookie
Public Methods
 MethodDefined by
  
UTMCookie(name:String, inURL:String, fields:Array, timespan:Number = 0)
Creates a new UTMCookie instance.
UTMCookie
  
fromSharedObject(data:Object):void
Deserialize data from a simple object.
UTMCookie
  
isEmpty():Boolean
Indicates if the cookie is empty.
UTMCookie
  
isExpired():Boolean
Indicates if the cookie has expired.
UTMCookie
  
reset():void
Reset the cookie.
UTMCookie
  
resetTimestamp(timespan:Number):void
Reset the timestamp of the cookie.
UTMCookie
  
toSharedObject():Object
Serialize data to a simple object.
UTMCookie
  
toString(showTimestamp:Boolean = false):String
Returns the String representation of the object.
UTMCookie
  
toURLString():String
Format data to render in the URL.
UTMCookie
  
valueOf():String
Returns the primitive value of the object.
UTMCookie
Protected Methods
 MethodDefined by
  
update():void
Update the cookie.
UTMCookie
Property detail
creationproperty
creation:Date  [read-write]

The cookie creation date

Implementation
    public function get creation():Date
    public function set creation(value:Date):void
expirationproperty 
expiration:Date  [read-write]

The cookie expiration date.

Implementation
    public function get expiration():Date
    public function set expiration(value:Date):void
fieldsproperty 
protected var fields:Array
inURLproperty 
protected var inURL:String
nameproperty 
protected var name:String
proxyproperty 
public var proxy:Buffer
Constructor detail
UTMCookie()constructor
public function UTMCookie(name:String, inURL:String, fields:Array, timespan:Number = 0)

Creates a new UTMCookie instance.

Parameters
name:String — The name of the cookie.
 
inURL:String — The name of cookie when is serialized in the url.
 
fields:Array — The fiels in the order of the cookie.
 
timespan:Number (default = 0) — The timespan value of the cookie.
Method detail
fromSharedObject()method
public function fromSharedObject(data:Object):void

Deserialize data from a simple object.

Parameters
data:Object
isEmpty()method 
public function isEmpty():Boolean

Indicates if the cookie is empty.

Returns
Boolean
isExpired()method 
public function isExpired():Boolean

Indicates if the cookie has expired.

Returns
Boolean
reset()method 
public function reset():void

Reset the cookie.

resetTimestamp()method 
public function resetTimestamp(timespan:Number):void

Reset the timestamp of the cookie.

Parameters
timespan:Number
toSharedObject()method 
public function toSharedObject():Object

Serialize data to a simple object.

Returns
Object
toString()method 
public function toString(showTimestamp:Boolean = false):String

Returns the String representation of the object.

Parameters
showTimestamp:Boolean (default = false)

Returns
String — the String representation of the object.
toURLString()method 
public function toURLString():String

Format data to render in the URL.

Returns
String
update()method 
protected function update():void

Update the cookie.

valueOf()method 
public function valueOf():String

Returns the primitive value of the object.

Returns
String — the primitive value of the object.