nashorn/src/jdk/internal/dynalink/linker/GuardingTypeConverterFactory.java
changeset 22669 75563515567f
parent 16245 6a1c6c8bc113
--- a/nashorn/src/jdk/internal/dynalink/linker/GuardingTypeConverterFactory.java	Thu Jan 30 19:28:40 2014 +0530
+++ b/nashorn/src/jdk/internal/dynalink/linker/GuardingTypeConverterFactory.java	Thu Jan 30 20:13:27 2014 +0100
@@ -96,19 +96,19 @@
  */
 public interface GuardingTypeConverterFactory {
     /**
-     * Returns a guarded invocation that receives an Object of the specified source type and returns an Object converted
-     * to the specified target type. The type of the invocation is targetType(sourceType), while the type of the guard
-     * is boolean(sourceType). Note that this will never be invoked for type conversions allowed by the JLS 5.3 "Method
-     * Invocation Conversion", see {@link TypeUtilities#isMethodInvocationConvertible(Class, Class)} for details. An
-     * implementation can assume it is never requested to produce a converter for these conversions.
+     * Returns a guarded type conversion that receives an Object of the specified source type and returns an Object
+     * converted to the specified target type. The type of the invocation is targetType(sourceType), while the type of
+     * the guard is boolean(sourceType). Note that this will never be invoked for type conversions allowed by the JLS
+     * 5.3 "Method Invocation Conversion", see {@link TypeUtilities#isMethodInvocationConvertible(Class, Class)} for
+     * details. An implementation can assume it is never requested to produce a converter for these conversions.
      *
      * @param sourceType source type
      * @param targetType the target type.
-     * @return a guarded invocation that can take an object (if it passes guard) and returns another object that is its
-     * representation coerced into the target type. In case the factory is certain it is unable to handle a conversion,
-     * it can return null. In case the factory is certain that it can always handle the conversion, it can return an
-     * unconditional invocation (one whose guard is null).
+     * @return a guarded type conversion that contains a guarded invocation that can take an object (if it passes guard)
+     * and return another object that is its representation coerced into the target type. In case the factory is certain
+     * it is unable to handle a conversion, it can return null. In case the factory is certain that it can always handle
+     * the conversion, it can return an unconditional invocation (one whose guard is null).
      * @throws Exception if there was an error during creation of the converter
      */
-    public GuardedInvocation convertToType(Class<?> sourceType, Class<?> targetType) throws Exception;
+    public GuardedTypeConversion convertToType(Class<?> sourceType, Class<?> targetType) throws Exception;
 }