4Suite API Documentation

Module Ft.Rdf.Parsers.Versa.DataTypes

Data type checking, conversion and ordering for Versa
Copyright 2005 Fourthought, Inc. (USA).
Detailed license and copyright information: http://4suite.org/COPYRIGHT
Project home, documentation, distributions: http://4suite.org/
Classes:
Functions:
Globals:

Classes

class NumberFunction
Create a new number

Methods

__init__(self, args)
evaluate(self, con)
class Resource(unicode)

Methods

__init__(self, s)
Overrides: __init__ from class unicode

Methods inherited from class unicode

__add__, __cmp__, __contains__, __getattribute__, __getitem__, __getnewargs__, __getslice__, __hash__, __len__, __mod__, __mul__, __new__, __repr__, __rmod__, __rmul__, __str__, capitalize, center, count, encode, endswith, expandtabs, find, index, isalnum, isalpha, isdecimal, isdigit, islower, isnumeric, isspace, istitle, isupper, join, ljust, lower, lstrip, replace, rfind, rindex, rjust, rstrip, split, splitlines, startswith, strip, swapcase, title, translate, upper, zfill

Methods inherited from class object

__delattr__, __reduce__, __reduce_ex__, __setattr__

Members

__dict__ = <attribute '__dict__' of 'Resource' objects>
__weakref__ = <attribute '__weakref__' of 'Resource' objects>

Members inherited from class object

__class__
class StringFunction
Create a new string

Methods

__init__(self, args)
evaluate(self, con)

Functions

Cmp(a, b)
CmpBoolean(a, b)
CmpList(a, b)
CmpNumber(a, b)
CmpResource = CmpString(a, b)
CmpSet(a, b)
CmpString(a, b)
IsBoolean = lambda(x)
IsList = lambda(x)
IsNumber = lambda(x)
IsResource = lambda(x)
IsSet = lambda(x)
IsString = lambda(x)
SyncType(testObject, obj)
ToBoolean(obj)
Convert to boolean
ToList(obj)
Convert to list
ToNumber(obj)
Convert to number
ToResource(obj)
Convert to resource
ToSet(obj)
Convert to set
ToString(obj)
Convert to string 1. If it is a string, then return 2. If it is a number then convert to a string 3. If it is a boolean, then convert to true or false 4. If a list or set, the coerce the first item. If empty ''

Globals

OBJECT_TYPE_RESOURCE = 'R'
OBJECT_TYPE_UNKNOWN = '?'