Skip to content
Snippets Groups Projects
Commit 8ea5f34f authored by Kevin Prudente's avatar Kevin Prudente Committed by GitHub
Browse files

Merge pull request #12 from quamotion/fixes/optional-arguments

Better support for optional arguments
parents 8d303307 8511c544
No related branches found
No related tags found
No related merge requests found
Showing
with 63 additions and 17 deletions
......@@ -13,6 +13,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS
/// <summary>
/// Gets or sets The ancestor node's inline style, if any, in the style inheritance chain.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public CSSStyle InlineStyle { get; set; }
/// <summary>
/// Gets or sets Matches of CSS rules matching the ancestor node in the style inheritance chain.
......
......@@ -25,10 +25,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS
/// <summary>
/// Gets or sets The associated range of the value text in the enclosing stylesheet (if available).
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public SourceRange ValueRange { get; set; }
/// <summary>
/// Gets or sets Computed length of media query expression (if applicable).
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public double ComputedLength { get; set; }
}
}
using MasterDevs.ChromeDevTools;
using MasterDevs.ChromeDevTools;using Newtonsoft.Json;
namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS
{
......
......@@ -17,6 +17,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS
/// <summary>
/// Gets or sets Selector range in the underlying resource (if available).
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public SourceRange Range { get; set; }
}
}
using MasterDevs.ChromeDevTools;
using MasterDevs.ChromeDevTools;using Newtonsoft.Json;
namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS
{
......
using MasterDevs.ChromeDevTools;
using MasterDevs.ChromeDevTools;using Newtonsoft.Json;
namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS
{
......
using MasterDevs.ChromeDevTools;
using MasterDevs.ChromeDevTools;using Newtonsoft.Json;
namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS
{
......
......@@ -17,42 +17,52 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas
/// <summary>
/// Gets or sets FunctionName
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string FunctionName { get; set; }
/// <summary>
/// Gets or sets Arguments
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public CallArgument[] Arguments { get; set; }
/// <summary>
/// Gets or sets Result
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public CallArgument Result { get; set; }
/// <summary>
/// Gets or sets IsDrawingCall
/// </summary>
public bool IsDrawingCall { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public bool? IsDrawingCall { get; set; }
/// <summary>
/// Gets or sets IsFrameEndCall
/// </summary>
public bool IsFrameEndCall { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public bool? IsFrameEndCall { get; set; }
/// <summary>
/// Gets or sets Property
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string Property { get; set; }
/// <summary>
/// Gets or sets Value
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public CallArgument Value { get; set; }
/// <summary>
/// Gets or sets SourceURL
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string SourceURL { get; set; }
/// <summary>
/// Gets or sets LineNumber
/// </summary>
public long LineNumber { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public long? LineNumber { get; set; }
/// <summary>
/// Gets or sets ColumnNumber
/// </summary>
public long ColumnNumber { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public long? ColumnNumber { get; set; }
}
}
......@@ -17,22 +17,27 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas
/// <summary>
/// Gets or sets Enum name, if any, that stands for the value (for example, a WebGL enum name).
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string EnumName { get; set; }
/// <summary>
/// Gets or sets Resource identifier. Specified for <code>Resource</code> objects only.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string ResourceId { get; set; }
/// <summary>
/// Gets or sets Object type. Specified for non <code>Resource</code> objects only.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string Type { get; set; }
/// <summary>
/// Gets or sets Object subtype hint. Specified for <code>object</code> type values only.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string Subtype { get; set; }
/// <summary>
/// Gets or sets The <code>RemoteObject</code>, if requested.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public Runtime.RemoteObject RemoteObject { get; set; }
}
}
......@@ -14,6 +14,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas
/// <summary>
/// Gets or sets Identifier of the frame containing document whose canvases are to be captured. If omitted, main frame is assumed.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string FrameId { get; set; }
}
}
using MasterDevs.ChromeDevTools;
using MasterDevs.ChromeDevTools;using Newtonsoft.Json;
namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas
{
......
......@@ -26,6 +26,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas
/// <summary>
/// Gets or sets String object group name to put result into (allows rapid releasing resulting object handles using <code>Runtime.releaseObjectGroup</code>).
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string ObjectGroup { get; set; }
}
}
......@@ -14,10 +14,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas
/// <summary>
/// Gets or sets Object wrapper for the evaluation result.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public Runtime.RemoteObject Result { get; set; }
/// <summary>
/// Gets or sets State of the <code>Resource</code> object.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public ResourceState ResourceState { get; set; }
}
}
......@@ -15,10 +15,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas
/// <summary>
/// Gets or sets StartOffset
/// </summary>
public long StartOffset { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public long? StartOffset { get; set; }
/// <summary>
/// Gets or sets MaxLength
/// </summary>
public long MaxLength { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public long? MaxLength { get; set; }
}
}
......@@ -21,10 +21,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas
/// <summary>
/// Gets or sets Describes current <code>Resource</code> state.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public ResourceStateDescriptor[] Descriptors { get; set; }
/// <summary>
/// Gets or sets Screenshot image data URL.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string ImageURL { get; set; }
}
}
......@@ -17,18 +17,22 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas
/// <summary>
/// Gets or sets String representation of the enum value, if <code>name</code> stands for an enum.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string EnumValueForName { get; set; }
/// <summary>
/// Gets or sets The value associated with the particular state.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public CallArgument Value { get; set; }
/// <summary>
/// Gets or sets Array of values associated with the particular state. Either <code>value</code> or <code>values</code> will be specified.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public ResourceStateDescriptor[] Values { get; set; }
/// <summary>
/// Gets or sets True iff the given <code>values</code> items stand for an array rather than a list of grouped states.
/// </summary>
public bool IsArray { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public bool? IsArray { get; set; }
}
}
......@@ -14,6 +14,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas
/// <summary>
/// Gets or sets Identifier of the frame containing document whose canvases are to be captured. If omitted, main frame is assumed.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string FrameId { get; set; }
}
}
using MasterDevs.ChromeDevTools;
using MasterDevs.ChromeDevTools;using Newtonsoft.Json;
namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas
{
......@@ -12,10 +12,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas
/// <summary>
/// Gets or sets If given, trace logs from the given frame were removed.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string FrameId { get; set; }
/// <summary>
/// Gets or sets If given, trace log with the given ID was removed.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string TraceLogId { get; set; }
}
}
......@@ -17,6 +17,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Console
/// <summary>
/// Gets or sets String label of this stack trace. For async traces this may be a name of the function that initiated the async call.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string Description { get; set; }
/// <summary>
/// Gets or sets Next asynchronous stack trace, if any.
......
......@@ -25,42 +25,52 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Console
/// <summary>
/// Gets or sets Console message type.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string Type { get; set; }
/// <summary>
/// Gets or sets Script ID of the message origin.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string ScriptId { get; set; }
/// <summary>
/// Gets or sets URL of the message origin.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string Url { get; set; }
/// <summary>
/// Gets or sets Line number in the resource that generated this message.
/// </summary>
public long Line { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public long? Line { get; set; }
/// <summary>
/// Gets or sets Column number in the resource that generated this message.
/// </summary>
public long Column { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public long? Column { get; set; }
/// <summary>
/// Gets or sets Repeat count for repeated messages.
/// </summary>
public long RepeatCount { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public long? RepeatCount { get; set; }
/// <summary>
/// Gets or sets Message parameters in case of the formatted message.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public Runtime.RemoteObject[] Parameters { get; set; }
/// <summary>
/// Gets or sets JavaScript stack trace for assertions and error messages.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public CallFrame[] StackTrace { get; set; }
/// <summary>
/// Gets or sets Asynchronous JavaScript stack trace that preceded this message, if available.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public AsyncStackTrace AsyncStackTrace { get; set; }
/// <summary>
/// Gets or sets Identifier of the network request associated with this message.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string NetworkRequestId { get; set; }
/// <summary>
/// Gets or sets Timestamp, when this message was fired.
......@@ -69,6 +79,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Console
/// <summary>
/// Gets or sets Identifier of the context where this message was created
/// </summary>
public long ExecutionContextId { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public long? ExecutionContextId { get; set; }
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment