01: /*
02: * Copyright 2007 Google Inc.
03: *
04: * Licensed under the Apache License, Version 2.0 (the "License"); you may not
05: * use this file except in compliance with the License. You may obtain a copy of
06: * the License at
07: *
08: * http://www.apache.org/licenses/LICENSE-2.0
09: *
10: * Unless required by applicable law or agreed to in writing, software
11: * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
12: * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
13: * License for the specific language governing permissions and limitations under
14: * the License.
15: */
16: package com.google.gwt.user.rebind.rpc.testcases.client;
17:
18: import com.google.gwt.user.client.rpc.IsSerializable;
19: import com.google.gwt.user.client.rpc.RemoteService;
20: import com.google.gwt.user.client.rpc.SerializationStreamReader;
21: import com.google.gwt.user.client.rpc.SerializationStreamWriter;
22:
23: /**
24: * Used to test that the
25: * {@link com.google.gwt.user.rebind.rpc.SerializableTypeOracleBuilder SerializableTypeOracleBuilder}
26: * will not fail if a manually serialized type has a field that is not
27: * serializables.
28: */
29: public interface ManualSerialization extends RemoteService {
30: /**
31: * Manually serialized. Field b is not serializable.
32: */
33: class A {
34: B b;
35: }
36:
37: /**
38: * Custom field serializer for {@link A}.
39: */
40: class A_CustomFieldSerializer {
41: public static void serialize(SerializationStreamWriter ssw,
42: A instance) {
43: }
44:
45: public static void deserialize(SerializationStreamReader ssr,
46: A instance) {
47: }
48: }
49:
50: /**
51: * Not automatically serializable.
52: */
53: class B implements IsSerializable {
54: Object obj;
55: }
56:
57: A getA();
58: }
|