Poltergeist (computer programming)
In computer programming a Poltergeist or Gypsy Wagon is a short lived object used to perform initialization or to invoke methods in other more permanent class.
A Poltergeist or Gypsy Wagon is an is an example of an anti-pattern.
The orginal definition is by Michael Akroyd 1996 - Object World West Conference.
As a gypsy wagon or a poltergeist appear and disappear mysteriously so are this short lived object. As a consequence the code is more difficult to mantain and there is unnecessary resource waste. The typical cause for this antipattern is poor object design. Gypsy wagon can be identified also by their name. Typically these are stateless "supervision" classes, used only to call methods of other classes, so several time are called "manager_" , "controller_", "start_process", etc..
To remove a Gypsy Wagon, delete the class and insert its functionality in the invoked class.