return NameToIdentifier.isHeuristicMatchForName(this.name, alias, name, NameToIdentifier.Simplifier.DEFAULT);
return NameToIdentifier.isHeuristicMatchForName(this.name, alias, name, NameToIdentifier.Simplifier.DEFAULT);
/** * Returns {@code true} if the {@linkplain org.apache.sis.referencing.AbstractIdentifiedObject#getName() * primary name} or an aliases of the given object matches the given name. The comparison ignores case, * some Latin diacritical signs and any characters that are not letters or digits. * * @param object the object for which to check the name or alias. * @param name the name to compare with the object name or aliases. * @return {@code true} if the primary name of at least one alias matches the specified {@code name}. * * @since 0.6 */ public boolean isHeuristicMatchForName(final IdentifiedObject object, final String name) { return NameToIdentifier.isHeuristicMatchForName(object.getName(), object.getAlias(), name, NameToIdentifier.Simplifier.DEFAULT); }
/** * Returns {@code true} if the {@linkplain org.apache.sis.referencing.AbstractIdentifiedObject#getName() * primary name} or an aliases of the given object matches the given name. The comparison ignores case, * some Latin diacritical signs and any characters that are not letters or digits. * * @param object the object for which to check the name or alias. * @param name the name to compare with the object name or aliases. * @return {@code true} if the primary name of at least one alias matches the specified {@code name}. * * @since 0.6 */ public boolean isHeuristicMatchForName(final IdentifiedObject object, final String name) { return NameToIdentifier.isHeuristicMatchForName(object.getName(), object.getAlias(), name, NameToIdentifier.Simplifier.DEFAULT); }
/** * Returns {@code true} if either the {@linkplain #getName() primary name} or at least * one {@linkplain #getAlias() alias} matches the given string according heuristic rules. * This method performs the comparison documented in the * {@linkplain AbstractIdentifiedObject#isHeuristicMatchForName(String) super-class}, * with the following additional flexibility: * * <ul> * <li>The {@code "D_"} prefix (used in ESRI datum names), if presents in the given name or in this datum name, * is ignored.</li> * <li>If this datum is an instance of {@link DefaultGeodeticDatum}, then the prime meridian name may also * be ignored.</li> * </ul> * * <div class="section">Future evolutions</div> * This method implements heuristic rules learned from experience while trying to provide inter-operability * with different data producers. Those rules may be adjusted in any future SIS version according experience * gained while working with more data producers. * * @param name the name to compare. * @return {@code true} if the primary name or at least one alias matches the specified {@code name}. */ @Override public boolean isHeuristicMatchForName(final String name) { return NameToIdentifier.isHeuristicMatchForName(super.getName(), super.getAlias(), name, Simplifier.INSTANCE); }
/** * Returns {@code true} if either the {@linkplain #getName() primary name} or at least * one {@linkplain #getAlias() alias} matches the given string according heuristic rules. * This method performs the comparison documented in the * {@linkplain AbstractIdentifiedObject#isHeuristicMatchForName(String) super-class}, * with the following additional flexibility: * * <ul> * <li>The {@code "D_"} prefix (used in ESRI datum names), if presents in the given name or in this datum name, * is ignored.</li> * <li>If this datum is an instance of {@link DefaultGeodeticDatum}, then the prime meridian name may also * be ignored.</li> * </ul> * * <div class="section">Future evolutions</div> * This method implements heuristic rules learned from experience while trying to provide inter-operability * with different data producers. Those rules may be adjusted in any future SIS version according experience * gained while working with more data producers. * * @param name the name to compare. * @return {@code true} if the primary name or at least one alias matches the specified {@code name}. */ @Override public boolean isHeuristicMatchForName(final String name) { return NameToIdentifier.isHeuristicMatchForName(super.getName(), super.getAlias(), name, Simplifier.INSTANCE); }
public boolean isHeuristicMatchForName(final String name) { final String meridian = primeMeridian.getName().getCode(); return NameToIdentifier.isHeuristicMatchForName(super.getName(), super.getAlias(), name, new Simplifier() { @Override protected CharSequence apply(CharSequence name) { name = super.apply(name);
public boolean isHeuristicMatchForName(final String name) { final String meridian = primeMeridian.getName().getCode(); return NameToIdentifier.isHeuristicMatchForName(super.getName(), super.getAlias(), name, new Simplifier() { @Override protected CharSequence apply(CharSequence name) { name = super.apply(name);
return NameToIdentifier.isHeuristicMatchForName(object.getName(), object.getAlias(), name, NameToIdentifier.Simplifier.DEFAULT);
return NameToIdentifier.isHeuristicMatchForName(object.getName(), object.getAlias(), name, NameToIdentifier.Simplifier.DEFAULT);