indra::ipc::russ Namespace Reference


Classes

class  UnbalancedBraces
class  UnknownDirective
class  BadDirective

Functions

def format_value_for_path
def format
def _find_sub_matches
def _build_query_string
def _fetch_url_directive
def _walk_resource


Detailed Description

\
@file russ.py
@brief Recursive URL Substitution Syntax helpers
@author Phoenix

Many details on how this should work is available on the wiki:
https://wiki.secondlife.com/wiki/Recursive_URL_Substitution_Syntax

Adding features to this should be reflected in that page in the
implementations section.

$LicenseInfo:firstyear=2007&license=mit$

Copyright (c) 2007-2008, Linden Research, Inc.

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
$/LicenseInfo$

Function Documentation

def indra::ipc::russ::_build_query_string (   query_dict  )  [private]

\
@breif given a dict, return a query string. utility wrapper for urllib.
@param query_dict input query dict
@returns Returns an urlencoded query string including leading '?'.

Definition at line 132 of file russ.py.

def indra::ipc::russ::_fetch_url_directive (   directive  )  [private]

Definition at line 151 of file russ.py.

def indra::ipc::russ::_find_sub_matches (   format_str  )  [private]

@brief Find all of the substitution matches.
@param format_str the RUSS conformant format string.	
@return Returns an array of depths of arrays of positional matches in input.

Definition at line 111 of file russ.py.

def indra::ipc::russ::_walk_resource (   resource,
  path 
) [private]

Definition at line 159 of file russ.py.

def indra::ipc::russ::format (   format_str,
  context 
)

@brief Format format string according to rules for RUSS.
@see https://osiris.lindenlab.com/mediawiki/index.php/Recursive_URL_Substitution_Syntax
@param format_str The input string to format.
@param context A map used for string substitutions.
@return Returns the formatted string. If no match, the braces remain intact.

Definition at line 60 of file russ.py.

Referenced by LLFloaterImagePreview::draw(), LLImageDXT::encodeDXT(), LLFloaterTopObjects::handleReply(), LLTexLayer::renderImageRaw(), LLSpinCtrl::updateEditor(), LLSliderCtrl::updateText(), and LLMultiSliderCtrl::updateText().

Here is the caller graph for this function:

def indra::ipc::russ::format_value_for_path (   value  ) 

Definition at line 48 of file russ.py.


Generated on Fri May 16 09:42:28 2008 for SecondLife by  doxygen 1.5.5