dto
Can a DTO have instance methods returning derived values?
Is it ever acceptable for a DTO to have instance methods which return derived values based on the DTO\'s data?Or should DTOs be pure data containers with no additional methods (other than getters/sett[详细]
2022-12-20 05:06 分类:问答Entity to DTO conversion with JPA
I\'m using DataNucleus as a JPA implementation to store my classes in my web application.I use a set of converters which all have toDTO() and fromDTO().[详细]
2022-12-20 00:52 分类:问答How to specify if a T4 file should produce any output
I am using T4 for generation of some DTO classes + mappers. I am splitting the files in a number of re-usable bits (some of which containing common methods, some others common procedures) and includi[详细]
2022-12-19 23:38 分类:问答How to handle and organize DTOs for different context?
When using simple DTOs in various scenarios I have frequently run into the same kind of problem and I always wondered whether there\'s a better way to deal with it.[详细]
2022-12-19 22:52 分类:问答Is is ever appropriate to put functionality in a DTO?
Is it ever appropriate to put functionality other t开发者_高级运维han basic setters and getters in a DTO?Well, in a number of scenarios you may well need some serialization code (for whatever serializ[详细]
2022-12-18 13:27 分类:问答Handling invalid values with ModelBinder in ASP.NET MVC 1.0
First of all some context: I have a form, where I post back some objects that are automatically materialized into objects by MVCs built-in ModelBinder:[详细]
2022-12-18 12:48 分类:问答How to generate Haml views instead of erb
I\'m building an app with Rails 2.3.4 and using script/generate controller home index to generate a controller and home page. I\'ve got Haml installed. I get an erb file:[详细]
2022-12-18 10:54 分类:问答C# Business Object Architecture question regarding Business and DTO objects
Background We have our own Business Object Architecture, a much lighter (...and loosely based on, but does\'nt actually use...) version of the \"CSLA\" business object framework with similar usage, v[详细]
2022-12-18 10:14 分类:问答DTOs : Several DTO (and Assemblers) for the same resource
I often need, depending on cases, of several DTOs for a same resource. Take the example of photo Albums. Depending of what i want to display, i\'ll need different data into my DTOs (creation thru a f[详细]
2022-12-17 02:41 分类:问答Mapping Validation Attributes From Domain Entity to DTO
I have a standard Domain Layer entity: public class Product { public int Id { get; set; } public string Name { get; set; }[详细]
2022-12-17 01:21 分类:问答