public function getOptionCAML () {

		$xml = '';

		// if fields are specified
		if(sizeof($this->fields) > 0) {
			$xml .= $this->api->viewFieldsXML($this->fields);
		}
		
		// If view, add to xml.
		if($this->view !== NULL) $xml .= '<viewName>' . $this->view . '</viewName>';
			
		return $xml;
	}