prepare Models for PCL

This commit is contained in:
2013-09-11 22:31:32 +02:00
parent c7565d7684
commit f2134b8c80
4 changed files with 33 additions and 9 deletions
@@ -1,5 +1,4 @@
using RestSharp;
using System;
using System;
using System.Collections.Generic;
namespace PocketSharp.Models
@@ -1,6 +1,4 @@
using RestSharp;
using ServiceStack.Text;
using System.Collections.Generic;
using System.Collections.Generic;
namespace PocketSharp.Models
{
@@ -26,11 +24,11 @@ namespace PocketSharp.Models
{
List<object> actions = new List<object>();
Actions.ForEach(action => actions.Add(action.Convert()));
//Actions.ForEach(action => actions.Add(action.Convert()));
return new List<Parameter>()
{
Utilities.CreateParam("actions", JsonSerializer.SerializeToString(actions))
// Utilities.CreateParam("actions", JsonSerializer.SerializeToString(actions))
};
}
}
@@ -0,0 +1,28 @@
namespace PocketSharp.Models
{
/// <summary>
/// Parameter
/// </summary>
public class Parameter
{
/// <summary>
/// Name of the parameter
/// </summary>
public string Name { get; set; }
/// <summary>
/// Value of the parameter
/// </summary>
public object Value { get; set; }
/// <summary>
/// Return a human-readable representation of this parameter
/// </summary>
/// <returns>String</returns>
public override string ToString()
{
return string.Format("{0}={1}", Name, Value);
}
}
}
@@ -1,5 +1,4 @@
using RestSharp;
using System;
using System;
using System.Collections.Generic;
namespace PocketSharp.Models