102
ComPonent-oriented develoPment and assemblY
In the POS example, let us consider the consumption of the ITableBiz service
registered by the Table component. e GuestUI component is in need of this
service. Inside the GuestUI component, we have a TableBizHolder class, which
serves as the helper class to locate the ITableBiz service. e code of the helper
method getTa bleBiz() inside the TableBizHolder class is presented:
public ITableBiz getTableBiz() {
ServiceReference<ITableBiz>
tableBizServiceRef=bundleContext
.getServiceReference(ITableBiz.class);
return bundleContext.getService(tableBizServiceRef);
}
e service layer provides a procedural service model where the publishing bundle
takes the responsibility of publishing the ser ...