code: public function serialize() {
  		$properties = $this->getSerializeVars();
  		
  		$data = array();
  		
  		foreach ($properties as $p) {
  			$data[$p] = $this->$p;
  		}
  		
  		return json_encode($data);
  	}
docs: Returns serialized string
  We presume there will not be some complex objects
  only integers/strings etc
  
  @return string JSON string with values of selected properties