I have a typical InMemory OData Producer from odata4j sample code
public static void main(String[] args) {
final InMemoryProducer producer = new InMemoryProducer("InMemoryODataProducer",10);
producer.register(ResultRow.class,"Results", Funcs.wrap(new ThrowingFunc<Iterable<ResultRow>>() {
public Iterable<ResultRow> apply() throws Exception {
return getResults(>>>>>>>>>myParam<<<<<<<<<<<<<<);
}
}), "Id");
DefaultODataProducerProvider.setInstance(producer);
ODataProducerUtil.hostODataServer("http://localhost:8080/InMemoryODataProducer.svc/");
(...)
How can I receive a customParam to use for retrieving concrete results given OData architecture? For instance, let's imagine, I want to specify the database as well with the url and I'd like to call
http://localhost:8014/InMemoryODataProducer.svc/Results?$top=2&$orderby=id---->&(database_schema=)myParam
It's indeed something less expected than a database id, I am not looking for any standard way to specify database in OData but to learn how to pass generic custom params.
Thanks!