001: package com.sun.xml.ws.resources;
002:
003: import com.sun.xml.ws.util.localization.Localizable;
004: import com.sun.xml.ws.util.localization.LocalizableMessageFactory;
005: import com.sun.xml.ws.util.localization.Localizer;
006:
007: /**
008: * Defines string formatting method for each constant in the resource file
009: *
010: */
011: public final class EncodingMessages {
012:
013: private final static LocalizableMessageFactory messageFactory = new LocalizableMessageFactory(
014: "com.sun.xml.ws.resources.encoding");
015: private final static Localizer localizer = new Localizer();
016:
017: public static Localizable localizableFAILED_TO_READ_RESPONSE(
018: Object arg0) {
019: return messageFactory.getMessage("failed.to.read.response",
020: arg0);
021: }
022:
023: /**
024: * Failed to read a response: {0}
025: *
026: */
027: public static String FAILED_TO_READ_RESPONSE(Object arg0) {
028: return localizer
029: .localize(localizableFAILED_TO_READ_RESPONSE(arg0));
030: }
031:
032: public static Localizable localizableEXCEPTION_INCORRECT_TYPE(
033: Object arg0) {
034: return messageFactory.getMessage("exception.incorrectType",
035: arg0);
036: }
037:
038: /**
039: * incorrect type. Expected java.lang.Exception, found {0}
040: *
041: */
042: public static String EXCEPTION_INCORRECT_TYPE(Object arg0) {
043: return localizer
044: .localize(localizableEXCEPTION_INCORRECT_TYPE(arg0));
045: }
046:
047: public static Localizable localizableEXCEPTION_NOTFOUND(Object arg0) {
048: return messageFactory.getMessage("exception.notfound", arg0);
049: }
050:
051: /**
052: * exception class: {0} not found in the model!
053: *
054: */
055: public static String EXCEPTION_NOTFOUND(Object arg0) {
056: return localizer.localize(localizableEXCEPTION_NOTFOUND(arg0));
057: }
058:
059: public static Localizable localizableXSD_UNEXPECTED_ELEMENT_NAME(
060: Object arg0, Object arg1) {
061: return messageFactory.getMessage("xsd.unexpectedElementName",
062: arg0, arg1);
063: }
064:
065: /**
066: * unexpected element name: expected={0}, actual: {1}
067: *
068: */
069: public static String XSD_UNEXPECTED_ELEMENT_NAME(Object arg0,
070: Object arg1) {
071: return localizer
072: .localize(localizableXSD_UNEXPECTED_ELEMENT_NAME(arg0,
073: arg1));
074: }
075:
076: public static Localizable localizableNESTED_DESERIALIZATION_ERROR(
077: Object arg0) {
078: return messageFactory.getMessage("nestedDeserializationError",
079: arg0);
080: }
081:
082: /**
083: * deserialization error: {0}
084: *
085: */
086: public static String NESTED_DESERIALIZATION_ERROR(Object arg0) {
087: return localizer
088: .localize(localizableNESTED_DESERIALIZATION_ERROR(arg0));
089: }
090:
091: public static Localizable localizableXSD_UNKNOWN_PREFIX(Object arg0) {
092: return messageFactory.getMessage("xsd.unknownPrefix", arg0);
093: }
094:
095: /**
096: * unknown prefix "{0}"
097: *
098: */
099: public static String XSD_UNKNOWN_PREFIX(Object arg0) {
100: return localizer.localize(localizableXSD_UNKNOWN_PREFIX(arg0));
101: }
102:
103: public static Localizable localizableNESTED_ENCODING_ERROR(
104: Object arg0) {
105: return messageFactory.getMessage("nestedEncodingError", arg0);
106: }
107:
108: /**
109: * encoding error: {0}
110: *
111: */
112: public static String NESTED_ENCODING_ERROR(Object arg0) {
113: return localizer
114: .localize(localizableNESTED_ENCODING_ERROR(arg0));
115: }
116:
117: public static Localizable localizableUNKNOWN_OBJECT() {
118: return messageFactory.getMessage("unknown.object");
119: }
120:
121: /**
122: * don't know how to write object: {0}
123: *
124: */
125: public static String UNKNOWN_OBJECT() {
126: return localizer.localize(localizableUNKNOWN_OBJECT());
127: }
128:
129: public static Localizable localizableINCORRECT_MESSAGEINFO() {
130: return messageFactory.getMessage("incorrect.messageinfo");
131: }
132:
133: /**
134: * can't write object! unexpected type: {0}
135: *
136: */
137: public static String INCORRECT_MESSAGEINFO() {
138: return localizer.localize(localizableINCORRECT_MESSAGEINFO());
139: }
140:
141: public static Localizable localizableNESTED_SERIALIZATION_ERROR(
142: Object arg0) {
143: return messageFactory.getMessage("nestedSerializationError",
144: arg0);
145: }
146:
147: /**
148: * serialization error: {0}
149: *
150: */
151: public static String NESTED_SERIALIZATION_ERROR(Object arg0) {
152: return localizer
153: .localize(localizableNESTED_SERIALIZATION_ERROR(arg0));
154: }
155:
156: public static Localizable localizableNO_SUCH_CONTENT_ID(Object arg0) {
157: return messageFactory.getMessage("noSuchContentId", arg0);
158: }
159:
160: /**
161: * There''s no attachment for the content ID "{0}"
162: *
163: */
164: public static String NO_SUCH_CONTENT_ID(Object arg0) {
165: return localizer.localize(localizableNO_SUCH_CONTENT_ID(arg0));
166: }
167:
168: }
|