If asked to find a marshaller for a pure interface, use the marshaller
for Object. git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2700 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
//
|
||||
// $Id: FieldMarshaller.java,v 1.4 2002/12/21 00:44:25 mdb Exp $
|
||||
// $Id: FieldMarshaller.java,v 1.5 2003/07/11 01:22:16 ray Exp $
|
||||
|
||||
package com.threerings.io;
|
||||
|
||||
@@ -39,8 +39,13 @@ public abstract class FieldMarshaller
|
||||
createMarshallers();
|
||||
}
|
||||
|
||||
// if we have an exact match, use that
|
||||
Class ftype = field.getType();
|
||||
if (ftype.isInterface()) {
|
||||
// if the class is a pure interface, use Object.
|
||||
ftype = Object.class;
|
||||
}
|
||||
|
||||
// if we have an exact match, use that
|
||||
FieldMarshaller fm = (FieldMarshaller)_marshallers.get(ftype);
|
||||
|
||||
// otherwise if the class is a streamable, use the streamable
|
||||
|
||||
Reference in New Issue
Block a user