Zum Inhalt springen

Plain old CLR object

aus Wikipedia, der freien Enzyklopädie
Dies ist eine alte Version dieser Seite, zuletzt bearbeitet am 30. April 2015 um 02:58 Uhr durch 68.184.198.186 (Diskussion). Sie kann sich erheblich von der aktuellen Version unterscheiden.

Vorlage:Redirect Plain Old CLR Object or POCO is a play on the term POJO, from the Java EE programming world (which was coined by Martin Fowler in 2000 Referenzfehler: Es fehlt ein schließendes </ref>. and are persistence ignorant objects. In .NET terms, the word is most often used in the programmatic sense, to differentiate a non-serviced component (see MTS) from a "standard object". It can also be used in a tongue-in-cheek manner, referencing the perceived complexity and invasiveness of Java-based programming frameworks such as the legacy EJB2.

POCO is often incorrectly expanded to Plain Old C# Object, but POCOs can be created with any language targeting the CLR. An alternative acronym sometimes used is PONO,<ref>See, for example, a reference to PONO in this whitepaper: [http://www.springframework.net/doc-latest/reference/pdf/spring-net-reference.pdf Spring Some benefits of POCO objects are:

  • Allows a simple storage mechanism for data, and simplifies serialization/passing data through layers.
  • Goes hand-in-hand with dependency injection, and the repository pattern.
  • Minimized complexity and dependencies on other layers (higher layers only care about the POCOs, POCOs don't care about anything) which facilitates loose coupling.
  • Increases testability through simplification.

See also

References


Vorlage:Comput-lang-stub