c# 3.0 - Refactoring: Extracting interface -
i refactoring existing code. i've extracted interfaces existing classes. have created separate class library holds such interfaces. problem have classes structures , enums. these classes have methods returning these structures , enums.
i want extract interface these class. worried structures , enums. can't have these structures , enums extracted in interface , hence methods returning structure , enums not reflect in extraction.
how can overcome situation wherein want have structure , enums in extracted interface? need break structure , have use members of interface? how can define methods returning structure in interface?
structures , enums shouldn't nested- unlike classes, part of 'public contract' of type, , you'd typically extract them own files , put them in shared class library interfaces.
Comments
Post a Comment