Click here to Skip to main content
15,504,703 members
Home / Discussions / C#
   

C#

 
AnswerRe: Parentheses vs curly brackets Pin
Nathan Minier27-Dec-17 7:32
professionalNathan Minier27-Dec-17 7:32 
GeneralRe: Parentheses vs curly brackets Pin
User9874327-Dec-17 10:03
professionalUser9874327-Dec-17 10:03 
GeneralRe: Parentheses vs curly brackets Pin
Nathan Minier27-Dec-17 10:10
professionalNathan Minier27-Dec-17 10:10 
QuestionSerialize class with multiple different schemas Pin
hpjchobbes26-Dec-17 3:53
hpjchobbes26-Dec-17 3:53 
AnswerRe: Serialize class with multiple different schemas Pin
BillWoodruff26-Dec-17 6:25
mveBillWoodruff26-Dec-17 6:25 
GeneralRe: Serialize class with multiple different schemas Pin
hpjchobbes27-Dec-17 4:20
hpjchobbes27-Dec-17 4:20 
GeneralRe: Serialize class with multiple different schemas Pin
Pete O'Hanlon27-Dec-17 5:05
mvaPete O'Hanlon27-Dec-17 5:05 
AnswerRe: Serialize class with multiple different schemas Pin
jschell26-Dec-17 8:28
jschell26-Dec-17 8:28 
Serialization has nothing to do with functionality. It is solely about data. So it doesn't matter how you modify/update/create that data.


hpjchobbes wrote:
On a Delete request, I have to only supply the ID and the EditSequence fields


What you are referring to is generally about a 'difference'.

And it has nothing to do with the object itself.

The object represents a set of data and functionality associated with the data.

You are attempting to push functionality that involves a specific API and delivery of that data into the object itself. Bad idea.

What needs to happen is that the API layer (your code) needs to understand what it needs to deliver and then provide a way to do that. And not one that relies on the object to do it.

To provide a difference you MUST have two instances of the object. A before and an after. Then the API layer provides a way to either generally or specifically define the difference.

Be very careful in your design decision because a general approach ties one to the idea that ALL objects will be delivered using a difference. If there is even one exception then one must break the architecture to deal with it. Which is not the same an understanding that many objects, but not all, need to be handled with a difference.

One part of handling a difference also requires that one must be able to define the 'id'. That might not solely be one attribute. A general solution would require a way to recognize the specific attribute(s) that are the 'id'. That would either require metadata or hard coded by each object. One way, there ARE other ways, to provide the id is to require an interface on the the object that returns, as a string (generic solution) the id value.
AnswerRe: Serialize class with multiple different schemas Pin
Gerry Schmitz26-Dec-17 13:49
mveGerry Schmitz26-Dec-17 13:49 
GeneralRe: Serialize class with multiple different schemas Pin
hpjchobbes27-Dec-17 4:26
hpjchobbes27-Dec-17 4:26 
GeneralRe: Serialize class with multiple different schemas Pin
Gerry Schmitz28-Dec-17 7:28
mveGerry Schmitz28-Dec-17 7:28 
QuestionType Casting from OleDb Value Types Returns Invalid Cast Exception Pin
User9874326-Dec-17 0:09
professionalUser9874326-Dec-17 0:09 
AnswerRe: Type Casting from OleDb Value Types Returns Invalid Cast Exception Pin
Gerry Schmitz26-Dec-17 13:28
mveGerry Schmitz26-Dec-17 13:28 
GeneralRe: Type Casting from OleDb Value Types Returns Invalid Cast Exception Pin
User9874326-Dec-17 13:52
professionalUser9874326-Dec-17 13:52 
GeneralRe: Type Casting from OleDb Value Types Returns Invalid Cast Exception Pin
User9874326-Dec-17 14:02
professionalUser9874326-Dec-17 14:02 
QuestionAwait/Async Question Pin
Kevin Marois24-Dec-17 11:51
professionalKevin Marois24-Dec-17 11:51 
AnswerRe: Await/Async Question Pin
Dave Kreskowiak24-Dec-17 16:15
mveDave Kreskowiak24-Dec-17 16:15 
GeneralRe: Await/Async Question Pin
Kevin Marois24-Dec-17 16:22
professionalKevin Marois24-Dec-17 16:22 
QuestionGetting a list of Key pressed Pin
Kenneth Haugland22-Dec-17 10:52
mvaKenneth Haugland22-Dec-17 10:52 
AnswerRe: Getting a list of Key pressed Pin
Kenneth Haugland23-Dec-17 6:10
mvaKenneth Haugland23-Dec-17 6:10 
AnswerRe: Getting a list of Key pressed Pin
Gerry Schmitz23-Dec-17 6:58
mveGerry Schmitz23-Dec-17 6:58 
GeneralRe: Getting a list of Key pressed Pin
Kenneth Haugland23-Dec-17 11:14
mvaKenneth Haugland23-Dec-17 11:14 
GeneralRe: Getting a list of Key pressed Pin
Gerry Schmitz23-Dec-17 19:38
mveGerry Schmitz23-Dec-17 19:38 
SuggestionMessage Closed Pin
22-Dec-17 0:20
professionalmatthewproctor22-Dec-17 0:20 
GeneralRe: Looking for feedback for new .Net / C# error tracking and reporting tool Pin
OriginalGriff22-Dec-17 1:57
mveOriginalGriff22-Dec-17 1:57 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.