Skip to content

An example of use of CORBA

Hello

CORBA (Common Object Request Broker Architecture) is a standart defined by OMG (Object Management Group), this let distributed object from different languages and OS to communicate. It also provides total transparency in the communication. The IDL (Interface Definition Language) is the tecnology used to describe the interfaces. IDL has your own data types, that are mapped to the data types in other languages. There is an IDL compiler, it generates the codes that do the communication.

But how it works? We have some definitions in a .idl file, in this case Bank-idl (remember to change the filename).

Acessing the files, you will see a lot of definitions like:

Module definition:

module banco {

Definition of data type valor as double

typedef double valor;

Definition of the transacao struct

struct transacao {
unsigned long data; // Formato: ddmmyyyy
string<12> descricao;
valor quantia;
};

Definition of some methos, vars and exceptions

interface auto_atendimento {
readonly attribute string boas_vindas;
valor saldo ( in conta c )
raises ( conta_inval );
void extrato ( in conta c,
out transacoes t, out valor saldo )
raises ( conta_inval );
void transferencia ( in conta origem,
in conta destino, in valor v )
raises ( conta_inval, saldo_insuf );
void investimento ( in conta c,
in aplicacao apl, in valor v )
raises ( conta_inval, saldo_insuf );
};

With this file you can generate a lot of different interfaces compiled to different languages. To generate the interfaces in Java use:

idlj -fall bank.idl

It will generate many files inside a banco folder, with the .java files. Now you just have to code what each method will do.

Example of implementation of a bank service and a client in Java using CORBA and IDL

Matheus

PS: This is just a introduction to CORBA. It uses a lot of other definitions as Object Management Architecture and others

References:
My Professor Frank page.
http://en.wikipedia.org/wiki/Common_Object_Request_Broker_Architecture

Published injava

3,925 Comments

  1. I just couldnt leave your website before saying that I really enjoyed the useful information you offer to your visitors… Will be back often to check up on new stuff you post!

  2. uk gambling triennial review, bonauka penalties for illegal gambling, Titus, machine and odds of winning pokies united states, or usa $200 no deposit bonus
    200 free spins

  3. One thing I want to touch upon is that fat burning plan fast is possible by the perfect diet and exercise. People’s size not just affects the look, but also the quality of life. Self-esteem, melancholy, health risks, plus physical ability are impacted in excess weight. It is possible to make everything right whilst still having a gain. Should this happen, a problem may be the perpetrator. While an excessive amount food rather than enough exercise are usually at fault, common health conditions and key prescriptions can greatly amplify size. Kudos for your post here.

  4. Richardemops Richardemops

    Если ситуация связана с потерей сознания, судорогами, выраженными нарушениями дыхания, тяжелой передозировкой или острым психозом, домашней процедуры может быть недостаточно. В таких случаях необходима экстренная медицинская помощь. После осмотра нарколог также может сделать вывод, что пациенту безопаснее находиться в стационаре.
    Изучить вопрос подробнее – вызвать нарколога на дом в Воронеже

  5. Обратиться за профессиональной помощью стоит не только после многонедельного употребления. У некоторых людей серьезные проблемы развиваются уже через несколько дней запоя. Значение имеют возраст, состояние здоровья, стаж алкоголизма и количество выпитого алкоголя. Поэтому заранее определить безопасный срок невозможно: решение принимает врач после оценки конкретного человека.
    Изучить вопрос подробнее – помощь вывод из запоя

  6. buy poker machine united kingdom, best online bingo sites united kingdom and online slots australia paypal, or
    united statesn red rock casino spa [Kathy] regulation

  7. Anthonywep Anthonywep

    Наркологическая помощь на дому может включать консультацию, осмотр, вывод из запоя, детоксикацию, капельницу, снятие абстинентного синдрома и рекомендации по дальнейшему лечению зависимости. Первый вызов позволяет определить, какие услуги нужны сейчас и требуется ли клиника. Если состояние тяжелое, врач рекомендует стационар. Воронеж обслуживается выездной службой по условиям конкретного центра, а заказать обращение можно по телефону или через сайт.
    Изучить вопрос подробнее – вызов нарколога на дом Воронеж

Leave a Reply

Your email address will not be published. Required fields are marked *