switch ( sink.getType() ) {
case NodeTypeEnums.JoinNode : {
writeBehaviours( (BetaNode) sink, context);
//context.out.println( "JoinNode" );
for ( LeftTuple childLeftTuple = leftTuple.getFirstChild(); childLeftTuple != null; childLeftTuple = (LeftTuple) childLeftTuple.getLeftParentNext() ) {
stream.writeShort( PersisterEnums.RIGHT_TUPLE );
int childSinkId = childLeftTuple.getLeftTupleSink().getId();
stream.writeInt( childSinkId );
stream.writeInt( childLeftTuple.getRightParent().getFactHandle().getId() );
//context.out.println( "RightTuple int:" + childLeftTuple.getLeftTupleSink().getId() + " int:" + childLeftTuple.getRightParent().getFactHandle().getId() );
writeLeftTuple( childLeftTuple,