Mar. 21st, 2012

juan_gandhi: (Default)
        try {
            require(iAmOk, getClass().getSimpleName() + " is not properly initialized");
            require(msg instanceof Message.BlaBlaBlaRequest, "wrong request type " + msg.getClass().getSimpleName());

            Message.BlaBlaBlaRequest rq = (Message.BlaBlaBlaRequest) msg;
            require(rq.thing_id != null && !rq.thing_id.isEmpty(), "thing id missing");
            
            byte[] bytes = someone.getThing(rq.thing_id);
            require(bytes != null && bytes.length > 0, "thing not found");
            
            return Message.l2map(hashmap("thing", (Message) Message.blob(bytes))); // casting due to broken variance in Java
        } catch (Failure f) {
            return f.report();
        } catch (Exception e) {
            return error(e);
        }

juan_gandhi: (Default)
ruvru:"Большой взрыв, в результате которого образовалась Вселенная, произошел в результате действия законов физики, и для него не нужно было вмешательство Бога. К такому выводу пришел известный американский физик Стивен Хокинг..."

Profile

juan_gandhi: (Default)
Juan-Carlos Gandhi

September 2025

S M T W T F S
 1 2345 6
78 9 10 111213
14 151617 181920
21222324252627
282930    

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Sep. 19th, 2025 11:07 pm
Powered by Dreamwidth Studios