"Joshua Kugler" <[EMAIL PROTECTED]> writes:
> [I've tried posting this twice: once through Google's smtp servers and
> once via our smtp servers, (both times with my From address being my
> Gmail address, which is the address I have registered for Google
> Groups). I have yet to see it show up in my inbox or in the group's
> list of messages. Anyone have any ideas? I'd really rather not have
> to use the web interface to post all the time.]
I don't use the web interface... :-) It might be some MUA configuration
error.
> Is there any option to return the data as a python pickle? With a
Sure!
class MyClass(Controller):
def index(self):
pass
def __get_data_to_serve(self, *args, **kwargs):
# Get and return your data in a suitable way to your methods reuse it
@expose()
def exposed_method(self, *args, **kwargs):
data = self.__get_data_to_serve(*args, **kwargs)
# Return what you need to the web interface
def _this_returns_pickle(self, *args, **kwargs):
data = self.__get_data_to_serve(*args, **kwargs)
# build and return pickle
With the use of RuleDispatch you could even abstract the different names.
> good Pythoon GUI toolkit (Qt, Gtk, Wx, etc) you could make a really
> nice front end to a nice back-end data service. I realize I could use
> XML-RPC or JSON, but I thought, "Why not keep it in Python's native
> format, and avoid the overhead of conversion?" As well as a lot less
> bandwidth needed, at least in the case of XML-RPC vs. Pickle. I'm
> sure it wouldn't be that hard to add. I'll do it myself, if someone
> wants to point me to the right place in the code. :)
>
> Comments?
>From past discussions it was seen that such a thing doesn't belong to TG
because of how simple it is to implement it (see my code sample above)...
Nothing prevents you from adding something and providing it as, e.g., another
template option.
I believe that it belongs in TG the changes needed to provide enough entry
points so that you can write it and publish it outside of TG core...
--
Jorge Godoy <[EMAIL PROTECTED]>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"TurboGears Trunk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/turbogears-trunk?hl=en
-~----------~----~----~----~------~----~------~--~---