same class, opposite namespaces, proceed simplify?


i'm operative webservice offers roughly repetitious formula opposing twin namesspaces. lets contend instance pigfeet horsefeet, both namespaces enclose feet category formula works feet category requires biased same namespace.



right formula i'm forced something this:



if( _animaltype == animaltype.pig )
{
//namespace pigfeet
pigfeet.feet feet = new feet();
feet.washfeet();
}

if( _animaltype == animaltype.horse )
{
//namespace horsefeet
horsefeet.feet feet = new feet();
feet.washfeet();
}


this withdrawal me lots repetitious code. there proceed select namespace some-more dynamically?



Comments

Popular posts from this blog

list macos calm editors formula editors

how hibernate @any-related annotations?

why does floated <input> control floated component slip over too distant right ie7, nonetheless firefox?