Skip to content

Instantly share code, notes, and snippets.

@nvcnvn
Last active December 19, 2017 10:12
Show Gist options
  • Save nvcnvn/8f3899b37b2872324bf1cfcfa8aec13c to your computer and use it in GitHub Desktop.
Save nvcnvn/8f3899b37b2872324bf1cfcfa8aec13c to your computer and use it in GitHub Desktop.
@Service
public class Car {
public void Move(Destination destination) {}
}
@Service
public class Transporter {
@Autowired
private Car vehicle;
public void Deliver(Lady prettyOne, Destination to) {
makeOutWith(prettyOne);
hitAllTheBadGuysAt(to)
}
private void makeOutWith(Lady prettyOne) {
// ...
}
private void hitAllTheBadGuysAt(Destination to) {
vehical.Move(to)
// then full of violence
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment