1

Topic: Question about Interface Segregation Principle

Greetings, prompt, please, than was specific badly not to follow this principle? Well here our interface is admissible contains two groups of methods - each group of methods concerns separate functionality. Than was specific this interface is bad? Whether refers to a linkage or connectivity (principles GRASP)?

2

Re: Question about Interface Segregation Principle

Hello, Maxim Rogozhin, you wrote: > Greetings, > prompt, please, than was specific badly not to follow this principle? Well here our interface is admissible contains two groups of methods - each group of methods concerns separate functionality. Than was specific this interface is bad? It is logical, that there was one interface inherited from two. In each interface the group of methods would contain. And it is better to be inherited at once from two interfaces if needed, without superfluous 3rd. Whether > refers to a linkage or connectivity (principles GRASP)? If only logical coherence.

3

Re: Question about Interface Segregation Principle

> the interface contains two groups of methods.... Than was specific this interface is bad? It is obvious, if these pieces can be implemented separately, make it it does not turn out. Well and ,  half of interface is necessary only, all the same it is necessary to implement and give it all. Whether > refers to a linkage or connectivity (principles GRASP)?  concerns very much. Only not from implementation, and from the interface.

4

Re: Question about Interface Segregation Principle

Hello, ylem, you wrote: Y> Only not from implementation, and from the interface. Can explain?

5

Re: Question about Interface Segregation Principle

Hello, Maxim Rogozhin, you wrote: > Greetings, > prompt, please, than was specific badly not to follow this principle? Well here our interface is admissible contains two groups of methods - each group of methods concerns separate functionality. Than was specific this interface is bad? Whether > refers to a linkage or connectivity (principles GRASP)? And what the good? At us two different facts are collected in one place. If it wanted to us to change logic of one group of methods it will be easily possible to break operation of other group of methods if to one group of methods to us one more method it affects all classes which wanted to add implement this interface even if they do not use it, and at implementation leave an empty body of a method.

6

Re: Question about Interface Segregation Principle

Hello, Maxim Rogozhin, you wrote: > Greetings, > prompt, please, than was specific badly not to follow this principle? Well here our interface is admissible contains two groups of methods - each group of methods concerns separate functionality. Than was specific this interface is bad? The less the client knows about the one whom it causes - the better. In the programmer of the client of temptation will not cause a method which is not necessary to it, and at the programmer of the server will be more possibilities in the extension of a functional of two server interfaces, than one (it is logical that probability to affect only one interface above, accordingly and easier with regress).

7

Re: Question about Interface Segregation Principle

Hello, Maxim Rogozhin, you wrote: > Hello, ylem, you wrote: Y>> Only not from implementation, and from the interface. > Can explain? In those sources which I saw, high cohesion speaks from implementation. As, , here  begin that One of the methods, Discharge (), lacks cohesion because it does not touch any of the class's private members.

8

Re: Question about Interface Segregation Principle

> prompt, please, than was specific badly not to follow this principle? Well here our interface is admissible contains two groups of methods - each group of methods concerns separate functionality. Than was specific this interface is bad? It is bad that it is impossible to implement only one of two multifunctions. At usage there can be additional dependences. Whether > refers to a linkage or connectivity (principles GRASP)? It is necessary  to look attentively, that it for methods. Most likely breaks principle Low Coupling. Precisely concerns principles SOLID. Breaks Interface Segregation Principle.