|
|
|
|
|
by FuzzyDunlop
4642 days ago
|
|
It doesn't feel like it's enterprise enough to be realistic. class TwoBaconRashersInsideTwoSlicesOfBreadFactory {
/* Make a sandwich
* <p>
* Construct a foodstuff consisting of two slices
* of bread with two slices of bacon.
* @return TwoBaconRashersInsideTwoSlicesOfBread a sandwich
*/
Public TwoBaconRashersInsideTwoSlicesOfBread getSandwich () {
BaconRasherFactory pig = new BaconRasherFactory();
BaconRasherInstance bacon1 = pig.getBaconRasher();
BaconRasherInstance bacon2 = pig.getBaconRasher();
SliceOfBreadFactory loaf = new SliceOfBreadFactory();
SliceOfBread bread1 = loaf.getSliceOfBread();
SliceOfBread bread2 = loaf.getSliceOfBread();
return new TwoBaconRashersInsideTwoSlicesOfBread(bread1, bacon1, bacon2, bread2);
}
Or something... trying to do Enterprise Java is hard. |
|
https://github.com/EnterpriseQualityCoding/FizzBuzzEnterpris...