OMG IDL Example
module Shopping {
/* structure of an item */
struct Item {
string item_name;
float item_price;
};
typedef sequence <Item> Basket;
/* class GoShopping */
interface GoShopping {
exception NotEnoughMoney
{float needed};
attribute float money;
void buy (in Basket, out Basket)
raises (NotEnoughMoney);
};
};
module
defines a naming context
interface
defines a CORBA class
operation
defines a method
data type
defines parameters, attributes, exceptions and return values
Previous slide
Next slide
Back to first slide
View graphic version