You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tuscany.apache.org by js...@apache.org on 2013/02/11 06:54:45 UTC

svn commit: r1444662 [2/3] - in /tuscany/sca-cpp/trunk/components/logic: ./ nuvem/

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/join.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/join.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/join.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/join.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,24 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+import string
+
+def get(r, sep, l):
+    s = sep.get(r)
+    lv = l.get(r)
+    return string.join(() if lv is None else lv, '' if s is None else s)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/keychain.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/keychain.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/keychain.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/keychain.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,38 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, n, a):
+    nv = n.get(r)
+    ntv = nv[1:] if nv[0:1] == "'" else nv
+    av = a.get(r)
+
+    content = filter(lambda e: e[0] == "'content", av[0])
+    account = filter(lambda e: e[0] == "'account", () if len(content) == 0 else content[0])
+    keys = filter(lambda e: e[0] == "'keys", () if len(account) == 0 else account[0])
+    key = filter(lambda e: e[0] == "'key", () if len(keys) == 0 else keys[0])
+    ekey = () if len(key) == 0 else key[0]
+    akey = () if len(ekey) < 2 else ekey[1]
+
+    def namedkey(k):
+        return len(filter(lambda e: e[0] == "'@name" and e[1] == ntv, k)) != 0
+
+    def keyvalue(k):
+        return filter(lambda e: e[0] == "'@value", k)
+
+    kv = map(keyvalue, filter(namedkey, akey))
+    return None if len(kv) == 0 else kv[0][0][1]
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/last.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/last.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/last.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/last.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,25 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, l):
+    lv = l.get(r)
+    if lv is None:
+        return None
+    if len(lv) == 0:
+        return None
+    return lv[len(lv) - 1]
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/left.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/left.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/left.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/left.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,21 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, n):
+    vn = n.get(r)
+    return 'left: {0:g}px'.format(round(0 if vn is None else float(vn), 0))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/lesser.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/lesser.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/lesser.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/lesser.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, a, b):
+    return a.get(r) < b.get(r)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/list_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/list_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/list_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/list_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,21 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(*args):
+    r = args[0]
+    return tuple(map(lambda x: x.get(r), args[1:len(args) - 1]))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/location.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/location.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/location.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/location.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,23 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, content):
+    if r[0:1] == ('setup',):
+        return 'setupLocationHandler();'
+
+    return content.get(r)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/lookup.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/lookup.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/lookup.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/lookup.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,55 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+# Return a list of name value pairs that match a name
+def get(r, n, l):
+    def isList(v):
+        if getattr(v, '__iter__', False) == False:
+            return False
+        if isinstance(v, basestring) or isinstance(v, dict):
+            return False
+        return True
+
+    def isAssoc(v):
+        return isList(v) and len(v) == 2 and isinstance(v[0], basestring) and v[0][0:1] == "'"
+
+    def lookup(nv, lv):
+        if lv == ():
+            return ()
+
+        # Check if list element is a name value pair assoc
+        a = lv[0]
+        if not isAssoc(a):
+            return lookup(nv, lv[1:])
+
+        # Got a match, return it and lookup rest of the list
+        an = "'" + a[0][2:] if a[0][0:2] == "'@" else a[0]
+        if an == nv:
+            return (a,) + lookup(nv, lv[1:])
+
+        # No match, lookup rest of the list
+        return lookup(nv, lv[1:])
+
+    def qsymbol(x):
+        if not isinstance(x, basestring):
+            return x
+        return x if x[0:1] == "'" else "'" + x
+
+    nv = n.get(r)
+    lv = l.get(r)
+    return lookup(qsymbol(nv), () if lv is None else lv)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/lowercase.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/lowercase.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/lowercase.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/lowercase.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,21 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, s):
+    vs = s.get(r)
+    return ('' if vs is None else str(vs)).lower()
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/map_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/map_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/map_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/map_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,26 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, item, transform, l):
+    iv = item.get(r)
+
+    def tfun(i):
+        return transform.get(((iv, i),) + r)
+
+    lv = l.get(r)
+    return tuple(map(tfun, () if lv is None else lv))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/max_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/max_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/max_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/max_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,21 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, l):
+    lv = l.get(r)
+    return max(() if lv is None else lv)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/min_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/min_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/min_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/min_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,21 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, l):
+    lv = l.get(r)
+    return min(() if lv is None else lv)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/mod.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/mod.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/mod.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/mod.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,22 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, n, x):
+    vx = x.get(r)
+    vn = n.get(r)
+    return float(0 if vx is None else vx) % float(1 if vn is None else vn)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/multiply.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/multiply.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/multiply.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/multiply.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,22 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, a, b):
+    va = a.get(r)
+    vb = b.get(r)
+    return float(0 if va is None else va) * float(0 if vb is None else vb)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/name.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/name.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/name.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/name.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, prop):
+    return "'" + prop.eval()
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/names.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/names.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/names.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/names.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,23 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, l):
+    lv = l.get(r)
+    if lv is None:
+        return lv
+    return tuple(map(lambda p: p[0], lv))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/nosqldb.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/nosqldb.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/nosqldb.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/nosqldb.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,29 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(id, db, appname):
+    return db.get(("'nosqldb", appname.eval()) + id);
+
+def post(id, val, db, appname):
+    return db.post(("'nosqldb", appname.eval()) + id, val);
+
+def put(id, val, db, appname):
+    return db.put(("'nosqldb", appname.eval()) + id, val);
+
+def delete(id, db, appname):
+    return db.delete(("'nosqldb", appname.eval()) + id);
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/not_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/not_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/not_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/not_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, expr):
+    return not expr.get(r)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/nothing.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/nothing.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/nothing.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/nothing.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r):
+    return None
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/now.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/now.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/now.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/now.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,24 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, f):
+    from datetime import datetime
+    fv = f.get(r)
+    if fv is None:
+        return datetime.now().ctime()
+    return datetime.now().strftime(fv)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/number.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/number.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/number.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/number.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, prop):
+    return float(prop.eval())
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/or_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/or_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/or_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/or_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,22 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, a, b):
+    va = a.get(r)
+    vb = b.get(r)
+    return (False if va is None else bool(va)) or (False if vb is None else bool(vb))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/pair.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/pair.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/pair.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/pair.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, a, b):
+    return (a.get(r), b.get(r))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/param.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/param.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/param.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/param.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,28 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, name, params):
+    def lookup(nv, lv):
+        if lv == ():
+            return None
+        a = lv[0]
+        if a[0] == nv:
+            return a[1]
+        return lookup(nv, lv[1:])
+
+    return lookup("'" + name.eval(), params.eval())
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/params.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/params.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/params.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/params.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, prop):
+    return prop.eval()
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/parse.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/parse.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/parse.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/parse.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,25 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+import re
+
+def get(r, expr, s):
+    ev = expr.get(r)
+    sv = s.get(r)
+    m = re.search('' if ev is None else ev, '' if sv is None else sv)
+    return () if m is None else m.groups()
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/path.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/path.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/path.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/path.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,21 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, prop):
+    p = prop.eval()
+    return p[2:] if p[0:1] == ('components',) else p
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/pi_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/pi_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/pi_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/pi_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,21 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r):
+    from math import pi
+    return pi
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/picalbum.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/picalbum.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/picalbum.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/picalbum.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,21 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, id, pic):
+    idv = id.get(r)
+    return pic.get((idv, ("'kind", 'photo'), ("'max-results", 20)))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/pixels.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/pixels.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/pixels.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/pixels.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,21 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, n):
+    vn = n.get(r)
+    return '{0:g}px'.format(round(0 if vn is None else float(vn), 0))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/post.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/post.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/post.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/post.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,28 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, coll, id, val):
+    def isList(v):
+        if getattr(v, '__iter__', False) == False:
+            return False
+        if isinstance(v, basestring) or isinstance(v, dict):
+            return False
+        return True
+
+    idv = id.get(r)
+    return coll.post(() if idv is None else idv if isList(idv) else (idv,), val.get(r))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/put.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/put.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/put.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/put.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,28 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, coll, id, val):
+    def isList(v):
+        if getattr(v, '__iter__', False) == False:
+            return False
+        if isinstance(v, basestring) or isinstance(v, dict):
+            return False
+        return True
+
+    idv = id.get(r)
+    return coll.put(() if idv is None else idv if isList(idv) else (idv,), val.get(r))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/random_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/random_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/random_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/random_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,33 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, m):
+    import random
+    mv = m.get(r)
+
+    def isList(v):
+        if getattr(v, '__iter__', False) == False:
+            return False
+        if isinstance(v, basestring) or isinstance(v, dict):
+            return False
+        return True
+
+    if isList(mv):
+        return random.choice(mv)
+
+    return random.random() * (1.0 if mv is None else mv)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/randoms.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/randoms.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/randoms.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/randoms.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,34 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, n, m):
+    import random
+    mv = m.get(r)
+    nv = n.get(r)
+
+    def isList(v):
+        if getattr(v, '__iter__', False) == False:
+            return False
+        if isinstance(v, basestring) or isinstance(v, dict):
+            return False
+        return True
+
+    if isList(mv):
+        return tuple(map(lambda i: random.choice(mv), tuple(range(0, int(0 if nv is None else nv)))))
+
+    return tuple(map(lambda i: random.random() * (1.0 if mv is None else mv), tuple(range(0, int(0 if nv is None else nv)))))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/range_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/range_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/range_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/range_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,22 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, a, b):
+    va = a.get(r)
+    vb = b.get(r)
+    return tuple(range(int(0 if va is None else va), int(0 if vb is None else vb)))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/realm.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/realm.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/realm.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/realm.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, prop):
+    return prop.eval()
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/reduce_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/reduce_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/reduce_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/reduce_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,27 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, item, accum, transform, init, l):
+    iv = item.get(r)
+    av = accum.get(r)
+
+    def tfun(a, i):
+        return transform.get(((av, a), (iv, i)) + r)
+
+    lv = l.get(r)
+    return reduce(tfun, () if lv is None else lv, init.get(r))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/replace.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/replace.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/replace.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/replace.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,23 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, fr, to, s):
+    vfr = fr.get(r)
+    vto = to.get(r)
+    vs = s.get(r)
+    return ('' if vs is None else str(vs)).replace('' if vfr is None else str(vfr), '' if vto is None else str(vto))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/rest.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/rest.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/rest.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/rest.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,23 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, l):
+    vl = l.get(r)
+    if vl is None:
+        return ()
+    return vl[1:]
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/reverse.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/reverse.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/reverse.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/reverse.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,25 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, l):
+    vl = l.get(r)
+    if vl is None:
+        return ()
+    rl = list(vl)
+    rl.reverse()
+    return tuple(rl)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/round_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/round_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/round_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/round_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,22 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, n, x):
+    vx = x.get(r)
+    vn = n.get(r)
+    return round(float(0 if vx is None else vx), int(0 if vn is None else vn))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/second.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/second.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/second.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/second.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,25 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, l):
+    lv = l.get(r)
+    if lv is None:
+        return lv
+    if len(lv) < 2:
+        return None
+    return lv[1]
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/select.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/select.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/select.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/select.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,72 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+# Return a list of name value pairs that match a name
+# Search through nested lists of name value pairs
+def get(r, p, l):
+    def isList(v):
+        if getattr(v, '__iter__', False) == False:
+            return False
+        if isinstance(v, basestring) or isinstance(v, dict):
+            return False
+        return True
+
+    def isAssoc(v):
+        return isList(v) and len(v) >= 2 and isinstance(v[0], basestring) and v[0][0:1] == "'"
+
+    def lookup(pv, lv):
+        if lv == ():
+            return ()
+        if isAssoc(lv):
+            lv = (lv,)
+
+        # Check if list element is a name value pair assoc
+        a = lv[0]
+        if not isAssoc(a):
+            # Lookup children if any and rest of list
+            if isList(a):
+                return lookup(pv, a) + lookup(pv, lv[1:])
+            return lookup(pv, lv[1:])
+
+        # Path segment match
+        an = "'" + a[0][2:] if a[0][0:2] == "'@" else a[0]
+        if an == pv[0]:
+            # Found leaf, return it and lookup rest of the list
+            if len(pv) == 1:
+                return (a,) + lookup(pv, lv[1:])
+            # Continue to lookup children if any plus rest of the list
+            return lookup(pv[1:], a[1:]) + lookup(pv, lv[1:])
+
+        # No match, lookup any children and rest of the list
+        if (isList(a[1])):
+            return lookup(pv, a[1]) + lookup(pv, a[2:]) + lookup(pv, lv[1:])
+        return lookup(pv, a[2:]) + lookup(pv, lv[1:])
+
+    def qsymbol(x):
+        if not isinstance(x, basestring):
+            return x
+        return x if x[0:1] == "'" else "'" + x
+
+    # Support path as a list or a dot separated string
+    lv = l.get(r)
+    pv = p.get(r)
+    if (isList(pv)):
+        return lookup(map(qsymbol, pv), () if lv is None else lv)
+
+    spv = map(qsymbol, qsymbol(pv)[1:].split('.'))
+    return lookup(spv, () if lv is None else lv)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/service.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/service.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/service.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/service.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, content):
+    return content.get(r)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/shuffle_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/shuffle_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/shuffle_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/shuffle_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,26 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, l):
+    from random import shuffle
+    vl = l.get(r)
+    if vl is None:
+        return ()
+    rl = list(vl)
+    shuffle(rl)
+    return tuple(rl)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/sin_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/sin_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/sin_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/sin_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,22 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, x):
+    from math import sin
+    vx = x.get(r)
+    return sin(float(0 if vx is None else vx))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/single.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/single.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/single.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/single.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, x):
+    return (x.get(r),)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/split.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/split.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/split.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/split.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,22 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, sep, s):
+    vsep = sep.get(r)
+    vs = s.get(r)
+    return tuple(('' if vs is None else str(vs)).split('' if vsep is None else str(vsep)))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/sqldb.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/sqldb.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/sqldb.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/sqldb.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,29 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(id, db, appname):
+    return db.get(("'sqldb", appname.eval()) + id);
+
+def post(id, val, db, appname):
+    return db.post(("'sqldb", appname.eval()) + id, val);
+
+def put(id, val, db, appname):
+    return db.put(("'sqldb", appname.eval()) + id, val);
+
+def delete(id, db, appname):
+    return db.delete(("'sqldb", appname.eval()) + id);
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/start.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/start.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/start.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/start.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, content):
+    return content.get(r)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/stop.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/stop.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/stop.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/stop.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, content):
+    return content.get(r)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/subtract.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/subtract.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/subtract.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/subtract.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,22 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, a, b):
+    va = a.get(r)
+    vb = b.get(r)
+    return float(0 if va is None else va) - float(0 if vb is None else vb)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/sum_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/sum_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/sum_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/sum_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,21 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, l):
+    vl = l.get(r)
+    return sum(() if vl is None else vl)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/text.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/text.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/text.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/text.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, prop):
+    return prop.eval()
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/timer.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/timer.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/timer.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/timer.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,26 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, msec, content):
+    if r[0:1] == ('setup',):
+        ms = msec.get(r)
+        if ms is None or ms == 0:
+            return ''
+        return 'setupIntervalHandler(' + str(int(ms)) + ');'
+
+    return content.get(r)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/top.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/top.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/top.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/top.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,21 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, n):
+    vn = n.get(r)
+    return 'top: {0:g}px'.format(round(0 if vn is None else float(vn), 0))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/transform.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/transform.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/transform.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/transform.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,26 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, x, y, d):
+    vx = x.get(r)
+    vy = y.get(r)
+    vd = d.get(r)
+    rx = round(float(0 if vx is None else vx), 0)
+    ry = round(float(0 if vy is None else vy), 0)
+    rd = round(float(0 if vd is None else vd), 0)
+    return 'position: absolute; -webkit-transform: translate3d({0:g}px,{1:g}px,0px) rotate({2:g}deg); -moz-transform: translate({0:g}px,{1:g}px) rotate({2:g}deg); -ms-transform: translate({0:g}px,{1:g}px) rotate({2:g}deg); transform: translate({0:g}px,{1:g}px) rotate({2:g}deg)'.format(rx, ry, rd)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/transition.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/transition.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/transition.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/transition.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,21 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, n):
+    vn = n.get(r)
+    return '-webkit-transition: all {0}s'.format(float(0 if vn is None else vn) / 1000.0)
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/triple.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/triple.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/triple.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/triple.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, a, b, c):
+    return (a.get(r), b.get(r), c.get(r))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/true_.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/true_.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/true_.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/true_.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,20 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r):
+    return True
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/twfollowers.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/twfollowers.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/twfollowers.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/twfollowers.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,21 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, twid, tw):
+    tid = twid.get(r)
+    return tw.get((("'screen_name", tid),))
+

Added: tuscany/sca-cpp/trunk/components/logic/nuvem/twfriends.py
URL: http://svn.apache.org/viewvc/tuscany/sca-cpp/trunk/components/logic/nuvem/twfriends.py?rev=1444662&view=auto
==============================================================================
--- tuscany/sca-cpp/trunk/components/logic/nuvem/twfriends.py (added)
+++ tuscany/sca-cpp/trunk/components/logic/nuvem/twfriends.py Mon Feb 11 05:54:42 2013
@@ -0,0 +1,21 @@
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#  
+#    http://www.apache.org/licenses/LICENSE-2.0
+#    
+#  Unless required by applicable law or agreed to in writing,
+#  software distributed under the License is distributed on an
+#  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#  KIND, either express or implied.  See the License for the
+#  specific language governing permissions and limitations
+#  under the License.
+
+def get(r, twid, tw):
+    tid = twid.get(r)
+    return tw.get((("'screen_name", tid),))
+