forked from opensourceBIM/BIMserver
-
Notifications
You must be signed in to change notification settings - Fork 0
Service Plugin
Ruben de Laat edited this page Jul 10, 2013
·
6 revisions
Service plugins can extend the functionality of a BIMserver by listening to notifications and acting upon them. For example a ClashDetection Service plugin could create a ClashDetection report as [ExtendedData] when a user checks in a new revision.
For this plugin you do not need implement any specific methods as long as you subclass [ServicePlugin]. You can register your services by calling the [register] method:
public void register(ServerDescriptor serverDescriptor, ServiceDescriptor serviceDescriptor, NotificationInterface notificationInterface) {
}It's best to register your services in the init method. You have to provide a [ServerDescriptor] and [ServiceDescriptor], here are examples for those:
ServerDescriptor serverDescriptor = StoreFactory.eINSTANCE.createServerDescriptor();
serverDescriptor.setTitle("Clashdetection");
ServiceDescriptor clashDetection = StoreFactory.eINSTANCE.createServiceDescriptor();
clashDetection.setName("Clashdetection");
clashDetection.setDescription("Clashdetection");
clashDetection.setNotificationProtocol(AccessMethod.INTERNAL);
clashDetection.setReadRevision(true);
clashDetection.setWriteExtendedData(true);
clashDetection.setTrigger(Trigger.NEW_REVISION);Example implementation code:
register(serverDescriptor, clashDetection, new NotificationInterfaceAdapter(){
@Override
public void newLogAction(SLogAction newRevisionNotification, SToken token, String apiUrl) throws UserException, ServerException {
ServiceInterface serviceInterface = getServiceInterface(token);
// Here goes your code
}
}Get Started
- Quick Guide
- Requirements Version 1.2
- Requirements Version 1.3
- Requirements Version 1.4
- Requirements Version 1.4 > 2015-09-12
- Requirements Version 1.5
- Download
- JAR Starter
- Setup
Deployment
- Ubuntu installation
- Windows installation
- Security
- Memory Usage
- More memory
- Performance statistics
- Large databases
Developers
- Service Interfaces
- Common functions
- Data Model
- Low Level Calls
- Endpoints
Clients
BIMServer Developers
- Plugins in 1.5
- Plugin Development
- Eclipse
- Eclipse Modeling Framework
- Embedding
- Terminology
- Database/Versioning
- IFC STEP Encoding
- Communication
- Global changes in 1.5
- Writing a service
- Services/Notifications
- BIMserver 1.5 Developers
- Extended data
- Extended data schema
- Object IDM
New developments
- New remote service interface
- Plugins new
- Deprecated
- New query language
- Visual query language
- Reorganizing BIMserver JavaScript API
General