/loggerhead/trunk

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/loggerhead/trunk
1 by Robey Pointer
initial checkin
1
# This module provides helper functions for the JSON part of your
2
# view, if you are providing a JSON-based API for your app.
3
4
# Here's what most rules would look like:
5
# @jsonify.when("isinstance(obj, YourClass)")
6
# def jsonify_yourclass(obj):
7
#     return [obj.val1, obj.val2]
8
# The goal is to break your objects down into simple values:
9
# lists, dicts, numbers and strings
10
11
from turbojson.jsonify import jsonify
12