GoogleCloudPlatform / endpoints-proto-datastore

Apache License 2.0
154 stars 52 forks source link

suggestion: _message_fields_schema black list instead of white list. #127

Open matantsu opened 9 years ago

matantsu commented 9 years ago

it would be nice if I could provide a list of properties to NOT include in the protorpc message. kind of the opposite of _message_fields_schema.

dhermes commented 9 years ago

Similarly, additional fields would also be nice (i.e. non-default, but valid).


Simplest way to get a blacklist would be to use:

fields = MyModel._DefaultFields()
for field in black_list:
    fields.remove(field)

and then use fields as _message_fields_schema.