net.sf.juoserver.protocol
Class ClasspathMessageDecoderProvider

java.lang.Object
  extended by net.sf.juoserver.protocol.ClasspathMessageDecoderProvider
All Implemented Interfaces:
MessageDecoderProvider

public class ClasspathMessageDecoderProvider
extends Object
implements MessageDecoderProvider

MessageDecoderProvider implementation that scans the classpath for Decodable Messages upon instantiation.

For performance reasons, the scanning is done only once.


Constructor Summary
ClasspathMessageDecoderProvider()
           
 
Method Summary
protected  void configureFrom(Class<?> baseClass)
           
 MessageDecoder getDecoder(byte firstByte)
          Retrieves a MessageDecoder for the message identified by the provided contents's {firstByte.
protected  Map<Byte,MessageDecoder> getDecoders()
           
protected  void init()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ClasspathMessageDecoderProvider

public ClasspathMessageDecoderProvider()
Method Detail

init

protected void init()

configureFrom

protected void configureFrom(Class<?> baseClass)

getDecoder

public MessageDecoder getDecoder(byte firstByte)
Description copied from interface: MessageDecoderProvider
Retrieves a MessageDecoder for the message identified by the provided contents's {firstByte.

Specified by:
getDecoder in interface MessageDecoderProvider
Parameters:
firstByte - raw contents' first byte
Returns:
a MessageDecoder for the message identified by the provided contents's first byte

getDecoders

protected Map<Byte,MessageDecoder> getDecoders()


Copyright © 2010-2012. All Rights Reserved.