datacontract Questions
1
I'm currently using wrapper classes for my DataSets ,in order to implement custom serialization. I would like to use DataContractSerializer (more like have to use it) but still support the custom s...
Parlor asked 1/7, 2010 at 8:58
2
Solved
I am using a Generic Class as a Response Data Contract. All is good and this is streamlining the design of my WCF service significantly.
Each request is given a standard response object with the f...
Brotherhood asked 4/2, 2009 at 1:53
2
Solved
How do I define DataContract for abstract classes in WCF?
I have a class "Person" which I communicate successfully using WCF. Now I add a new class "Foo" referenced from Person. All still good. B...
Personage asked 23/6, 2010 at 12:54
2
Solved
The answer to just about every single question about using C# with JSON seems to be "use JSON.NET", but that's not the answer I'm looking for.
The reason I say that is, from everything I've been a...
Catenoid asked 1/6, 2010 at 15:15
2
What is the purpose of IsReference property in DataContract? How does the request and response vary with this property applied?
Cholula asked 24/6, 2009 at 8:57
4
Solved
While using this code to serialize an object:
public object Clone()
{
var serializer = new DataContractSerializer(GetType());
using (var ms = new System.IO.MemoryStream())
{
serializer.WriteOb...
Consubstantial asked 10/3, 2010 at 13:2
2
I'm writing a WCF service and want to expose some custom configuration elements (e.g. Custom ConfigurationSection and ConnectionStringSettings) so that I can modify the service's configuration.
O...
Tani asked 30/10, 2008 at 13:59
6
I am building a set of WCF services that share common data contracts (or entities if you prefer). These are simple data transfer objects that are decorated with DataContract and DataMember attribut...
Stanwin asked 24/2, 2010 at 15:30
3
Solved
I have found that my WCF services work normally when the data types involved doesn't have the [DataContract], but the [Serializable] instead.
But all the WCF tutorials shows the first one instead ...
Vulgarian asked 16/12, 2009 at 1:46
1
Solved
what is the difference between class without DataContract attributes:
public class BankOperationResult
{
public int CurrentAmount { get; set; }
public bool Success { get; set; }
}
and the sam...
Covalence asked 27/11, 2009 at 22:6
3
You're at the service's end of the wire and you don't know your clients.
Why would you choose one over the other?
Stunning asked 13/7, 2009 at 12:27
2
I have a contract as follows:
[DataContract]
public class MyObj
{
[DataMember(IsRequired=true)]
public string StrA {get; private set;}
[DataMember(IsRequired=false)]
public string StrB {get; ...
Murderous asked 14/10, 2009 at 14:50
7
Soliciting feedback/options/comments regarding a "best" pattern to use for reference data in my services.
What do I mean by reference data?
Let's use Northwind as an example. An Order is related ...
Febrifacient asked 16/6, 2009 at 23:11
3
Solved
Using VS 2008 & .NET 3.5 SP1:
I am using WCF to allow clients to connect to a service that reads and writes database entries using Entity Framework. By default the entities that are generated ...
Gasconade asked 13/7, 2009 at 20:34
4
Solved
Given an operation contract such as:
[OperationContract]
void Operation(string param1, string param2, int param3);
This could be redesigned to:
[MessageContract]
public class OperationRequest
{...
Revealment asked 24/1, 2009 at 19:48
4
Solved
We've written a web service which uses a simple entity translator to map the values of DTO back on to "real" server side business objects. As part of this excercise. We have come across an "interes...
Alidus asked 11/5, 2009 at 7:37
2
Solved
I'm using a class library that exposes a few objects. These objects have a couple of properties that hold data my clients need. I'd like to create a WCF service that returns the objects to my clien...
Tomas asked 27/4, 2009 at 18:38
1
Solved
I'm trying to figure out the best way to save (serialize) and later open (deserialize) a tree structure. My structure is made up of various object types with different properties, but each inherits...
Parenthesize asked 10/4, 2009 at 2:46
3
Solved
Can I have a data contract of this shape??
[DataContract]
public class YearlyStatistic{
[DataMember]
public string Year{get;set;}
[DataMember]
public string StatisticName {get;set;}
[DataMembe...
Hewe asked 2/4, 2009 at 17:51
3
Solved
When defining a WCF data contract, which type should one use for collections/lists?
Should it be ICollection<T>,
IList<T>, T[] or...?
Should I use interface types or the concrete type...
Kp asked 27/2, 2009 at 12:10
2
Solved
I was wondering if anybody out there had some good tips/dos and don'ts for designing WCF contracts with a mind for web-service interoperability, both in terms of older Microsoft web service technol...
Bazluke asked 27/1, 2009 at 22:20
1
Solved
I have a WCF service hosted for internal clients - we have control of all the clients. We will therefore be using a data contracts library to negate the need for proxy generation. I would like to u...
Hix asked 5/10, 2008 at 21:20
© 2022 - 2024 — McMap. All rights reserved.