# Interface Segregation Principle

> A design rule that a client depends on an interface holding only the methods it uses.

Record: `architecture:interface-segregation`
Kind: principle
Layer: [Structural Core](https://banes-lab.com/records/layer/structural-core.md)
Severity: mandatory
Scope: interface, service, module
Canonical: https://banes-lab.com/ontology#architecture-interface-segregation

Listed in [Architecture principles](https://banes-lab.com/api/records/architecture.md), after [Autonomy](https://banes-lab.com/records/architecture/autonomy.md) and before [Dependency Inversion Principle (DIP)](https://banes-lab.com/records/architecture/dependency-inversion.md).

## Repair

- Refactored by: Split Interface, Extract Role Interface
- Detected by: unused interface method implementations
- Violated by: clients depending on unused methods
- Measured by: interface method usage ratio
- Enforced by: interface usage analysis, lint rules

## Requires

- [Role-Specific Interfaces](https://banes-lab.com/records/lexicon/role-specific-interfaces.md)

## Reinforces

- [Single Responsibility Principle (SRP)](https://banes-lab.com/records/architecture/single-responsibility.md)
- [Low Coupling](https://banes-lab.com/records/architecture/low-coupling.md)

## Enables

- [Consumer-Specific Contracts](https://banes-lab.com/records/lexicon/consumer-specific-contracts.md)

## Conflicts with

- [Fat Interface](https://banes-lab.com/records/lexicon/fat-interface.md)
- [Repository Dump](https://banes-lab.com/records/architecture/repository-dump.md)

## In tension with

- [Interface Proliferation](https://banes-lab.com/records/lexicon/interface-proliferation.md)

## Tensions

- [Interface Segregation Principle (ISP) / Interface Proliferation](https://banes-lab.com/records/tension/interface-proliferation-interface-segregation-principle-isp.md)

## Severity

- [mandatory](https://banes-lab.com/records/vocabulary/severity-mandatory.md)

## Category

- [SOLID / Object-Oriented Design](https://banes-lab.com/records/architecture-category/solid-object-oriented-design.md)

## Linked from

- [The structural domain](https://banes-lab.com/software-architecture/principles/the-structural-domain.md)
- [Anti-patterns](https://banes-lab.com/ontology/principles/architecture-category-anti-patterns.md)
- [Core Modular Design](https://banes-lab.com/ontology/principles/architecture-category-core-modular-design.md)
- [SOLID / Object-Oriented Design](https://banes-lab.com/ontology/lexicon/lexicon-category-solid-object-oriented-design.md)
- [Severity levels](https://banes-lab.com/ontology/schema/the-vocabulary-severity.md)
- [The resolutions](https://banes-lab.com/ontology/schema/the-resolutions.md)
