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

November 2025

S M T W T F S
       1
2345678
9101112131415
16171819202122
23242526272829
30      

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Nov. 4th, 2025 05:06 am
Powered by Dreamwidth Studios