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 45 additions and 15 deletions
using MasterDevs.ChromeDevTools;
using MasterDevs.ChromeDevTools;using Newtonsoft.Json;
namespace MasterDevs.ChromeDevTools.Protocol.Chrome.DOMStorage
{
......
using MasterDevs.ChromeDevTools;
using MasterDevs.ChromeDevTools;using Newtonsoft.Json;
namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Database
{
......
......@@ -11,14 +11,17 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Database
/// <summary>
/// Gets or sets ColumnNames
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string[] ColumnNames { get; set; }
/// <summary>
/// Gets or sets Values
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public object[] Values { get; set; }
/// <summary>
/// Gets or sets SqlError
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public Error SqlError { get; set; }
}
}
......@@ -21,10 +21,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets Stack trace where async operation was scheduled.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public Console.CallFrame[] StackTrace { get; set; }
/// <summary>
/// Gets or sets Asynchronous stack trace where async operation was scheduled, if available.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public Console.AsyncStackTrace AsyncStackTrace { get; set; }
}
}
using MasterDevs.ChromeDevTools;
using MasterDevs.ChromeDevTools;using Newtonsoft.Json;
namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
{
......
using MasterDevs.ChromeDevTools;
using MasterDevs.ChromeDevTools;using Newtonsoft.Json;
namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
{
......
using MasterDevs.ChromeDevTools;
using MasterDevs.ChromeDevTools;using Newtonsoft.Json;
namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
{
......
......@@ -21,6 +21,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets Location in the source code.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public Location FunctionLocation { get; set; }
/// <summary>
/// Gets or sets Location in the source code.
......@@ -37,6 +38,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets The value being returned, if the function is at return point.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public Runtime.RemoteObject ReturnValue { get; set; }
}
}
......@@ -13,6 +13,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets Entry key of a map-like collection, otherwise not provided.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public Runtime.RemoteObject Key { get; set; }
/// <summary>
/// Gets or sets Entry value.
......
......@@ -26,6 +26,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets Specifies in which isolated context to perform script run. Each content script lives in an isolated context and this parameter may be used to specify one of those contexts. If the parameter is omitted or 0 the evaluation will be performed in the context of the inspected page.
/// </summary>
public long ExecutionContextId { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public long? ExecutionContextId { get; set; }
}
}
......@@ -14,10 +14,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets Id of the script.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string ScriptId { get; set; }
/// <summary>
/// Gets or sets Exception details.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public ExceptionDetails ExceptionDetails { get; set; }
}
}
......@@ -18,6 +18,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets Allows breakpoints at the intemediate positions inside statements.
/// </summary>
public bool InterstatementLocation { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public bool? InterstatementLocation { get; set; }
}
}
......@@ -14,6 +14,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets Whether to capture stack traces for promise creation and settlement events (default: false).
/// </summary>
public bool CaptureStacks { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public bool? CaptureStacks { get; set; }
}
}
......@@ -22,22 +22,27 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets String object group name to put result into (allows rapid releasing resulting object handles using <code>releaseObjectGroup</code>).
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string ObjectGroup { get; set; }
/// <summary>
/// Gets or sets Specifies whether command line API should be available to the evaluated expression, defaults to false.
/// </summary>
public bool IncludeCommandLineAPI { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public bool? IncludeCommandLineAPI { get; set; }
/// <summary>
/// Gets or sets Specifies whether evaluation should stop on exceptions and mute console. Overrides setPauseOnException state.
/// </summary>
public bool DoNotPauseOnExceptionsAndMuteConsole { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public bool? DoNotPauseOnExceptionsAndMuteConsole { get; set; }
/// <summary>
/// Gets or sets Whether the result is expected to be a JSON object that should be sent by value.
/// </summary>
public bool ReturnByValue { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public bool? ReturnByValue { get; set; }
/// <summary>
/// Gets or sets Whether preview should be generated for the result.
/// </summary>
public bool GeneratePreview { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public bool? GeneratePreview { get; set; }
}
}
......@@ -18,10 +18,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets True if the result was thrown during the evaluation.
/// </summary>
public bool WasThrown { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public bool? WasThrown { get; set; }
/// <summary>
/// Gets or sets Exception details.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public ExceptionDetails ExceptionDetails { get; set; }
}
}
......@@ -17,22 +17,27 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets URL of the message origin.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string Url { 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 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 JavaScript stack trace for assertions and error messages.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public Console.CallFrame[] StackTrace { get; set; }
}
}
......@@ -13,6 +13,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets Location of the function, none for native functions.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public Location Location { get; set; }
/// <summary>
/// Gets or sets Name of the function.
......@@ -25,6 +26,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets Scope chain for this closure.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public Scope[] ScopeChain { get; set; }
}
}
......@@ -25,6 +25,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets If suspended, location where generator function was suspended (e.g. location of the last 'yield'). Otherwise, location of the generator function.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public Location Location { get; set; }
}
}
......@@ -18,6 +18,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets Async stack trace, if any.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public StackTrace AsyncStackTrace { get; set; }
}
}
......@@ -18,6 +18,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger
/// <summary>
/// Gets or sets Symbolic group name that can be used to release multiple objects.
/// </summary>
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string ObjectGroup { 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