서비스 공급자 인터페이스

Service provider interface

SPI(Service Provider Interface)는 제3자가 구현하거나 확장하기 위한 API이다.프레임워크 확장 및 교체 가능한 구성요소를 활성화하는 데 사용할 수 있다.[1][2][3]

세부 사항

Java 설명서:

서비스는 잘 알려진 인터페이스 및 (대개 추상적) 클래스의 집합이다.서비스 제공자는 서비스의 특정한 구현이다.제공자의 클래스는 일반적으로 인터페이스를 구현하고 서비스 자체에 정의된 클래스를 하위 클래스로 분류한다.서비스 제공자는 Java 플랫폼의 구현에서 일반적인 확장 디렉토리, 즉 jar 파일 형태로 설치될 수 있다.제공자들은 또한 그들을 애플리케이션의 클래스 경로에 추가하거나 다른 플랫폼별 수단에 의해 이용할 수 있게 할 수 있다.[4]

이 개념은 해당 도구를 사용하여 다른 플랫폼으로 확장될 수 있다.Java Runtime Environment에서 SPI는 다음에서 사용된다.[1][2]

참고 항목

참조

  1. ^ a b "Introduction to the Service Provider Interfaces". Oracle Java Documentation. Services are units of sound-handling functionality that are automatically available when an application program makes use of an implementation of the Java Sound API
  2. ^ a b Thribhuvan Thakur (November 18, 2009). "Service Provider Interface: Creating Extensible Java Applications". Developer.com. A service provider interface (SPI) is the set of public interfaces and abstract classes that a service defines. A SPI may be represented by a single interface (type) or abstract class or a set of interfaces or abstract classes that define the service contract.
  3. ^ Seacord, C. Robert & Wrage, Lutz (July 2002). "Replaceable Components and the Service Provider Interface". Software Engineering Institute (CMU).
  4. ^ "ServiceLoader".

외부 링크