oodt-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mattmann, Chris A (388J)" <chris.a.mattm...@jpl.nasa.gov>
Subject Re: svn commit: r1145358 - /oodt/trunk/balance/lib/pear/Core/ApplicationResponse.class.php
Date Mon, 11 Jul 2011 21:22:28 GMT
Hey Andrew,

Can you file a JIRA issue for this?

Cheers,
Chris

On Jul 11, 2011, at 2:15 PM, <ahart@apache.org> <ahart@apache.org> wrote:

> Author: ahart
> Date: Mon Jul 11 21:15:59 2011
> New Revision: 1145358
> 
> URL: http://svn.apache.org/viewvc?rev=1145358&view=rev
> Log:
> restored ability to associate arbitrary key/value data with a response object
> 
> Modified:
>    oodt/trunk/balance/lib/pear/Core/ApplicationResponse.class.php
> 
> Modified: oodt/trunk/balance/lib/pear/Core/ApplicationResponse.class.php
> URL: http://svn.apache.org/viewvc/oodt/trunk/balance/lib/pear/Core/ApplicationResponse.class.php?rev=1145358&r1=1145357&r2=1145358&view=diff
> ==============================================================================
> --- oodt/trunk/balance/lib/pear/Core/ApplicationResponse.class.php (original)
> +++ oodt/trunk/balance/lib/pear/Core/ApplicationResponse.class.php Mon Jul 11 21:15:59
2011
> @@ -40,6 +40,8 @@ class Org_Apache_Oodt_Balance_Core_Appli
> 	protected $stylesheets = array();
> 	protected $javascripts = array();
> 	
> +	protected $data;
> +
> 	const DYN_JS_TAG  = '<!-- JAVASCRIPTS -->';
> 	const DYN_CSS_TAG = '<!-- STYLESHEETS -->';
> 	
> @@ -246,6 +248,24 @@ class Org_Apache_Oodt_Balance_Core_Appli
> 	public function getFooterContent() {
> 		return $this->footer;
> 	}
> +
> +	public function data($key = null, $value = null) {
> +	       
> +		// Return the data store associated with this request
> +		if ($key == null && $value == null) {
> +			return $this->data;
> +		}
> +					
> +		// Return the stored value for the provided key
> +		if ($value == null) {
> +			return isset($this->data[$key]) 
> +				? $this->data[$key] 
> +				: null;
> +		}
> +															   
> +		// Set the stored value for the key to the provided value
> +		$this->data[$key] = $value;
> +	}
> 	
> 	public function addStylesheet($href,$condition='') {
> 		// Build the string for the css import
> 
> 


++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Chris Mattmann, Ph.D.
Senior Computer Scientist
NASA Jet Propulsion Laboratory Pasadena, CA 91109 USA
Office: 171-266B, Mailstop: 171-246
Email: chris.a.mattmann@nasa.gov
WWW:   http://sunset.usc.edu/~mattmann/
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Adjunct Assistant Professor, Computer Science Department
University of Southern California, Los Angeles, CA 90089 USA
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++


Mime
View raw message