1   /*
2    * SPDX-FileCopyrightText: none
3    * SPDX-License-Identifier: CC0-1.0
4    */
5   
6   package dev.metaschema.core.metapath.item.function.impl;
7   
8   import dev.metaschema.core.metapath.impl.AbstractMapKey;
9   import dev.metaschema.core.metapath.item.function.IMapKey;
10  import dev.metaschema.core.metapath.item.function.IStringMapKey;
11  
12  /**
13   * An implementation of a {@link IMapKey} that uses a string-based value.
14   */
15  public abstract class AbstractStringMapKey
16      extends AbstractMapKey
17      implements IStringMapKey {
18  
19    @Override
20    protected int generateHashCode() {
21      return asString().hashCode();
22    }
23  }