Changes between Version 7 and Version 8 of wxGUIDevelopment/Refactoring
- Timestamp:
- 08/02/13 00:59:45 (12 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
wxGUIDevelopment/Refactoring
v7 v8 87 87 ''This text is unclear as well as the right answer.'' 88 88 89 Or would be better to define interface class (similar to GrassInterface) to ensure exclusive89 Or would be better to define interface class (similar to !GrassInterface) to ensure exclusive 90 90 use of this interface? Private methods are probably mostly sufficient, however interface of 91 particular class can be wider than defined GrassInterface.91 particular class can be wider than defined !GrassInterface. 92 92 93 93 For example, some class A which is not expected to use the wider interface, provided by 94 94 class B, can use this wider interface when class A has direct access to class B. Consequently, 95 the class A depends on class B instead of GrassInterface interface. UsingGrassInterface96 layer ensures that class A depends on the GrassInterface, not the wider interface provided95 the class A depends on class B instead of !GrassInterface interface. Using !GrassInterface 96 layer ensures that class A depends on the !GrassInterface, not the wider interface provided 97 97 by the class B. 98 98 99 However, implementing the GrassInterface is little bit more difficult because beside the100 particular class (class B in example above), you have to implement also the GrassInterface99 However, implementing the !GrassInterface is little bit more difficult because beside the 100 particular class (class B in example above), you have to implement also the !GrassInterface 101 101 class.