/*
 * Licensed to the Apache Software Foundation (ASF) under one or more
 * contributor license agreements.  See the NOTICE file distributed with
 * this work for additional information regarding copyright ownership.
 * The ASF licenses this file to You under the Apache License, Version 2.0
 * (the "License"); you may not use this file except in compliance with
 * the License.  You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package org.apache.jackrabbit.oak.namepath;

public interface NameMapper {

    // TODO consider error handling
    String getOakName(String jcrName);

    // TODO consider error handling
    String getJcrName(String oakName);
}

@@ -881,114 +881,774 @@
    /
-/ TODO consider error handling%0A    String getOakName(String jcrName);%0A%0A    // TODO consider error handling
+**%0A     * Returns the Oak name for the given JCR name, or %7B@code null%7D if no%0A     * such mapping exists because the given JCR name contains an unknown%0A     * namespace URI or prefix, or is otherwise invalid.%0A     *%0A     * @param jcrName JCR name%0A     * @return Oak name, or %7B@code null%7D%0A     */%0A    String getOakName(String jcrName);%0A%0A    /**%0A     * Returns the JCR name for the given Oak name. The given name is%0A     * expected to have come from a valid Oak repository that contains%0A     * only valid names with proper namespace mappings. If that's not%0A     * the case, either a programming error or a repository corruption%0A     * has occurred and an appropriate unchecked exception gets thrown.%0A     *%0A     * @param oakName Oak name%0A     * @return JCR name%0A     */
 %0A   
@@ -1683,10 +1683,11 @@
 kName);%0A
+%0A
 %7D%0A

Improve exception handling