001package javax.visrec.spi; 002 003/** 004 * Returns information about the used implementation of visual recognition API 005 * @author Kevin Berendsen 006 * @since 1.0 007 */ 008public abstract class ImplementationService { 009 010 /** 011 * Get the name of the implementation 012 * @return name as {@code String} 013 */ 014 public abstract String getName(); 015 016 /** 017 * Get the major version of the implementation 018 * @return major version as {@code int} 019 */ 020 public abstract int getMajorVersion(); 021 022 /** 023 * Get the minor version of the implementation 024 * @return minor version as {@code int} 025 */ 026 public abstract int getMinorVersion(); 027 028 /** 029 * Returns the name, major and minor version of the implementation 030 * @return combined information in a {@code String} 031 */ 032 @Override 033 public final String toString() { 034 return getName() + " " + getMajorVersion() + "." + getMinorVersion(); 035 } 036}