From 0ee8ca632667110ad20fd78226368053286155dd Mon Sep 17 00:00:00 2001 From: svatal <swata@centrum.cz> Date: Wed, 9 Aug 2017 15:03:37 +0200 Subject: [PATCH] regenerated protocol --- .../Protocol/Chrome/Accessibility/AXNode.cs | 24 +++++-- .../Chrome/Accessibility/AXPropertySource.cs | 40 ----------- .../Chrome/Accessibility/AXRelatedNode.cs | 1 + .../Protocol/Chrome/Accessibility/AXValue.cs | 11 +-- .../Chrome/Accessibility/AXValueSource.cs | 12 +++- .../Accessibility/GetAXNodeCommandResponse.cs | 20 ------ .../Accessibility/GetPartialAXTreeCommand.cs | 3 +- .../Protocol/Chrome/Animation/Animation.cs | 1 + .../Animation/AnimationCanceledEvent.cs | 2 +- .../Chrome/Animation/AnimationCreatedEvent.cs | 2 +- .../Animation/AnimationPlayerCanceledEvent.cs | 17 ----- .../Animation/AnimationPlayerCreatedEvent.cs | 21 ------ .../Chrome/Animation/AnimationStartedEvent.cs | 2 +- .../Protocol/Chrome/CSS/CSSKeyframeRule.cs | 1 + .../Protocol/Chrome/CSS/CSSMedia.cs | 2 +- .../Protocol/Chrome/CSS/FontsUpdatedEvent.cs | 2 +- .../CSS/GetBackgroundColorsCommandResponse.cs | 1 + .../CSS/GetMatchedStylesForNodeCommand.cs | 10 --- .../GetMatchedStylesForNodeCommandResponse.cs | 17 ++++- .../Protocol/Chrome/CSS/LayoutTreeNode.cs | 5 +- .../CSS/SetStyleSheetTextCommandResponse.cs | 1 + .../Protocol/Chrome/CSS/ShorthandEntry.cs | 3 +- .../Protocol/Chrome/Canvas/Call.cs | 68 ------------------- .../Protocol/Chrome/Canvas/CallArgument.cs | 43 ------------ .../Chrome/Canvas/CaptureFrameCommand.cs | 20 ------ .../Chrome/Canvas/ContextCreatedEvent.cs | 17 ----- .../EvaluateTraceLogCallArgumentCommand.cs | 32 --------- ...uateTraceLogCallArgumentCommandResponse.cs | 25 ------- .../Chrome/Canvas/GetTraceLogCommand.cs | 26 ------- .../Protocol/Chrome/Canvas/ResourceState.cs | 32 --------- .../Chrome/Canvas/ResourceStateDescriptor.cs | 38 ----------- .../Chrome/Canvas/StartCapturingCommand.cs | 20 ------ .../Chrome/Canvas/TraceLogsRemovedEvent.cs | 23 ------- .../Chrome/Console/AsyncStackTrace.cs | 28 -------- .../Protocol/Chrome/Console/ConsoleMessage.cs | 48 +------------ .../Console/MessageRepeatCountUpdatedEvent.cs | 21 ------ .../Chrome/Console/MessagesClearedEvent.cs | 13 ---- .../Protocol/Chrome/DOM/EventListener.cs | 39 ----------- .../Protocol/Chrome/DOM/GetDocumentCommand.cs | 6 +- .../DOM/GetEventListenersForNodeCommand.cs | 24 ------- .../Chrome/DOM/GetFlattenedDocumentCommand.cs | 6 +- .../Protocol/Chrome/DOM/HighlightConfig.cs | 4 +- .../Protocol/Chrome/DOM/Node.cs | 6 +- .../Chrome/DOM/NodeHighlightRequestedEvent.cs | 2 +- .../Chrome/DOM/RequestChildNodesCommand.cs | 5 ++ .../Chrome/DOM/SetInspectModeCommand.cs | 13 ++-- .../Chrome/DOMDebugger/EventListener.cs | 5 +- .../DOMDebugger/GetEventListenersCommand.cs | 6 +- .../Chrome/Debugger/AsyncOperation.cs | 32 --------- .../Debugger/AsyncOperationCompletedEvent.cs | 17 ----- .../Debugger/AsyncOperationStartedEvent.cs | 17 ----- .../Protocol/Chrome/Debugger/BreakLocation.cs | 4 +- .../Debugger/ContinueToLocationCommand.cs | 5 -- .../Debugger/EnablePromiseTrackerCommand.cs | 20 ------ .../Debugger/EvaluateOnCallFrameCommand.cs | 9 ++- .../EvaluateOnCallFrameCommandResponse.cs | 7 +- .../Chrome/Debugger/ExceptionDetails.cs | 43 ------------ .../Chrome/Debugger/FunctionDetails.cs | 32 --------- .../Chrome/Debugger/GeneratorObjectDetails.cs | 31 --------- .../Debugger/GetBacktraceCommandResponse.cs | 24 ------- .../Debugger/GetPossibleBreakpointsCommand.cs | 4 +- .../Chrome/Debugger/GetPromiseByIdCommand.cs | 24 ------- .../GetStepInPositionsCommandResponse.cs | 20 ------ .../Debugger/GlobalObjectClearedEvent.cs | 13 ---- .../Protocol/Chrome/Debugger/PausedEvent.cs | 2 +- .../Chrome/Debugger/PromiseDetails.cs | 62 ----------------- .../Chrome/Debugger/PromiseUpdatedEvent.cs | 21 ------ .../Debugger/RestartFrameCommandResponse.cs | 6 +- .../Chrome/Debugger/RunScriptCommand.cs | 34 ---------- .../Protocol/Chrome/Debugger/Scope.cs | 3 + .../Debugger/ScriptFailedToParseEvent.cs | 23 +++++-- .../Chrome/Debugger/ScriptParsedEvent.cs | 26 +++++-- .../Chrome/Debugger/ScriptPosition.cs | 13 ++-- .../Chrome/Debugger/SetScriptSourceCommand.cs | 4 +- .../SetScriptSourceCommandResponse.cs | 11 ++- .../Chrome/Debugger/SetScriptSourceError.cs | 19 ------ .../Debugger/SetVariableValueCommand.cs | 8 +-- .../Chrome/Debugger/SkipStackFramesCommand.cs | 25 ------- ...etDefaultBackgroundColorOverrideCommand.cs | 1 + .../SetDeviceMetricsOverrideCommand.cs | 13 ++-- .../Emulation/SetVirtualTimePolicyCommand.cs | 3 +- .../Chrome/Emulation/ViewportChangedEvent.cs | 17 ----- .../VirtualTimeBudgetExpiredEvent.cs | 2 +- .../Protocol/Chrome/FileSystem/Entry.cs | 41 ----------- .../RequestDirectoryContentCommandResponse.cs | 24 ------- .../FileSystem/RequestFileContentCommand.cs | 38 ----------- .../RequestFileContentCommandResponse.cs | 29 -------- .../RequestFileSystemRootCommandResponse.cs | 24 ------- .../RequestMetadataCommandResponse.cs | 24 ------- .../HeapProfiler/StartSamplingCommand.cs | 1 + .../Protocol/Chrome/IO/ReadCommand.cs | 6 +- .../Chrome/Input/DispatchKeyEventCommand.cs | 1 + .../Input/SynthesizeScrollGestureCommand.cs | 7 +- .../EvaluateForTestInFrontendEvent.cs | 18 ----- .../Protocol/Chrome/Inspector/InspectEvent.cs | 18 ----- .../Protocol/Chrome/Log/EntryAddedEvent.cs | 2 +- .../Protocol/Chrome/Log/LogEntry.cs | 7 +- .../Protocol/Chrome/Network/Cookie.cs | 1 + .../EmulateNetworkConditionsCommand.cs | 1 + .../Protocol/Chrome/Network/EnableCommand.cs | 6 +- .../Chrome/Network/GetCookiesCommand.cs | 1 + .../Protocol/Chrome/Network/Initiator.cs | 9 +-- .../Chrome/Network/LoadingFailedEvent.cs | 5 ++ .../Protocol/Chrome/Network/Request.cs | 1 + .../Network/ResourceChangedPriorityEvent.cs | 2 +- .../Protocol/Chrome/Network/Response.cs | 1 + .../Chrome/Network/SecurityDetails.cs | 2 + .../Chrome/Network/SetCookieCommand.cs | 10 ++- .../Chrome/Network/WebSocketCreatedEvent.cs | 1 + .../Chrome/Page/CaptureScreenshotCommand.cs | 4 +- .../Chrome/Page/ConfigureOverlayCommand.cs | 4 +- .../Protocol/Chrome/Page/FrameResource.cs | 8 ++- .../Protocol/Chrome/Page/FrameResourceTree.cs | 28 +------- .../Page/GetAppManifestCommandResponse.cs | 1 + .../Protocol/Chrome/Page/NavigateCommand.cs | 1 + .../Chrome/Page/NavigationRequestedEvent.cs | 2 +- .../Chrome/Page/PrintToPDFCommandResponse.cs | 11 ++- .../Chrome/Page/ScreencastFrameEvent.cs | 3 +- .../Page/SetDeviceMetricsOverrideCommand.cs | 13 ++-- .../Chrome/Page/StartScreencastCommand.cs | 5 ++ .../Chrome/Power/DataAvailableEvent.cs | 14 ---- .../Protocol/Chrome/Profiler/Profile.cs | 14 ++-- .../Protocol/Chrome/Profiler/ProfileNode.cs | 6 +- .../SetShowViewportSizeOnResizeCommand.cs | 9 +-- .../Chrome/Runtime/AwaitPromiseCommand.cs | 6 +- .../Runtime/AwaitPromiseCommandResponse.cs | 1 + .../Protocol/Chrome/Runtime/CallArgument.cs | 12 ++-- .../Chrome/Runtime/CallFunctionOnCommand.cs | 14 +++- .../Runtime/CallFunctionOnCommandResponse.cs | 4 +- .../Chrome/Runtime/ConsoleAPICalledEvent.cs | 3 +- .../Chrome/Runtime/EvaluateCommand.cs | 16 ++++- .../Chrome/Runtime/EvaluateCommandResponse.cs | 7 +- .../Protocol/Chrome/Runtime/EventListener.cs | 31 --------- .../Chrome/Runtime/ExceptionDetails.cs | 7 +- .../Chrome/Runtime/ExceptionRevokedEvent.cs | 2 +- .../Chrome/Runtime/ExceptionThrownEvent.cs | 2 +- .../Runtime/ExecutionContextDescription.cs | 10 +-- .../Runtime/GetEventListenersCommand.cs | 24 ------- .../Runtime/GetPropertiesCommandResponse.cs | 1 + .../Chrome/Runtime/InspectRequestedEvent.cs | 2 +- .../Protocol/Chrome/Runtime/RemoteObject.cs | 1 + .../Chrome/Runtime/RunScriptCommand.cs | 19 ++++-- .../Protocol/Chrome/Runtime/StackTrace.cs | 19 ++++-- .../Security/SecurityStateChangedEvent.cs | 3 +- .../ServiceWorker/DebugOnStartUpdatedEvent.cs | 14 ---- .../ServiceWorker/DispatchMessageEvent.cs | 18 ----- .../ServiceWorkerRegistration.cs | 3 +- .../ServiceWorker/ServiceWorkerVersion.cs | 2 + .../ServiceWorker/WorkerCreatedEvent.cs | 18 ----- .../ServiceWorker/WorkerTerminatedEvent.cs | 14 ---- .../Protocol/Chrome/SystemInfo/GPUInfo.cs | 2 + .../Chrome/Target/AttachedToTargetEvent.cs | 2 +- .../Chrome/Target/CreateTargetCommand.cs | 7 +- .../Chrome/Target/DetachedFromTargetEvent.cs | 2 +- .../Target/ReceivedMessageFromTargetEvent.cs | 2 +- .../Chrome/Target/TargetCreatedEvent.cs | 2 +- .../Chrome/Target/TargetDestroyedEvent.cs | 2 +- .../Chrome/Tethering/AcceptedEvent.cs | 2 +- .../Chrome/Timeline/EventRecordedEvent.cs | 17 ----- .../Protocol/Chrome/Timeline/StartCommand.cs | 40 ----------- .../Protocol/Chrome/Timeline/TimelineEvent.cs | 51 -------------- .../Protocol/Chrome/Tracing/StartCommand.cs | 2 + .../Protocol/Chrome/Tracing/TraceConfig.cs | 14 +++- .../Chrome/Tracing/TracingCompleteEvent.cs | 1 + .../Worker/DispatchMessageFromWorkerEvent.cs | 18 ----- .../Chrome/Worker/WorkerCreatedEvent.cs | 22 ------ .../Chrome/Worker/WorkerTerminatedEvent.cs | 14 ---- .../SerializationTests.cs | 9 +-- 168 files changed, 401 insertions(+), 1827 deletions(-) delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Accessibility/AXPropertySource.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Accessibility/GetAXNodeCommandResponse.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Animation/AnimationPlayerCanceledEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Animation/AnimationPlayerCreatedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Canvas/Call.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Canvas/CallArgument.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Canvas/CaptureFrameCommand.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Canvas/ContextCreatedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Canvas/EvaluateTraceLogCallArgumentCommand.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Canvas/EvaluateTraceLogCallArgumentCommandResponse.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Canvas/GetTraceLogCommand.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Canvas/ResourceState.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Canvas/ResourceStateDescriptor.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Canvas/StartCapturingCommand.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Canvas/TraceLogsRemovedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Console/AsyncStackTrace.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Console/MessageRepeatCountUpdatedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Console/MessagesClearedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/DOM/EventListener.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/DOM/GetEventListenersForNodeCommand.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/AsyncOperation.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/AsyncOperationCompletedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/AsyncOperationStartedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/EnablePromiseTrackerCommand.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/ExceptionDetails.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/FunctionDetails.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/GeneratorObjectDetails.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/GetBacktraceCommandResponse.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/GetPromiseByIdCommand.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/GetStepInPositionsCommandResponse.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/GlobalObjectClearedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/PromiseDetails.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/PromiseUpdatedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/RunScriptCommand.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/SetScriptSourceError.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Debugger/SkipStackFramesCommand.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Emulation/ViewportChangedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/FileSystem/Entry.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestDirectoryContentCommandResponse.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestFileContentCommand.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestFileContentCommandResponse.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestFileSystemRootCommandResponse.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestMetadataCommandResponse.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Inspector/EvaluateForTestInFrontendEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Inspector/InspectEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Power/DataAvailableEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Runtime/EventListener.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Runtime/GetEventListenersCommand.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/ServiceWorker/DebugOnStartUpdatedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/ServiceWorker/DispatchMessageEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/ServiceWorker/WorkerCreatedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/ServiceWorker/WorkerTerminatedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Timeline/EventRecordedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Timeline/StartCommand.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Timeline/TimelineEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Worker/DispatchMessageFromWorkerEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Worker/WorkerCreatedEvent.cs delete mode 100644 source/ChromeDevTools/Protocol/Chrome/Worker/WorkerTerminatedEvent.cs diff --git a/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXNode.cs b/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXNode.cs index e9e8770..12b1147 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXNode.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXNode.cs @@ -15,8 +15,18 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Accessibility /// </summary> public string NodeId { get; set; } /// <summary> + /// Gets or sets Whether this node is ignored for accessibility + /// </summary> + public bool Ignored { get; set; } + /// <summary> + /// Gets or sets Collection of reasons why this node is hidden. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public AXProperty[] IgnoredReasons { get; set; } + /// <summary> /// Gets or sets This <code>Node</code>'s role, whether explicit or implicit. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public AXValue Role { get; set; } /// <summary> /// Gets or sets The accessible name for this <code>Node</code>. @@ -34,13 +44,19 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Accessibility [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public AXValue Value { get; set; } /// <summary> - /// Gets or sets Help. + /// Gets or sets All other properties + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public AXProperty[] Properties { get; set; } + /// <summary> + /// Gets or sets IDs for each of this node's child nodes. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public AXValue Help { get; set; } + public string[] ChildIds { get; set; } /// <summary> - /// Gets or sets All other properties + /// Gets or sets The backend ID for the associated DOM node, if any. /// </summary> - public AXProperty[] Properties { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? BackendDOMNodeId { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXPropertySource.cs b/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXPropertySource.cs deleted file mode 100644 index c6aee5f..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXPropertySource.cs +++ /dev/null @@ -1,40 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Accessibility -{ - /// <summary> - /// A single source for a computed AX property. - /// </summary> - [SupportedBy("Chrome")] - public class AXPropertySource - { - /// <summary> - /// Gets or sets The name/label of this source. - /// </summary> - public string Name { get; set; } - /// <summary> - /// Gets or sets What type of source this is. - /// </summary> - public AXPropertySourceType SourceType { get; set; } - /// <summary> - /// Gets or sets The value of this property source. - /// </summary> - public object Value { get; set; } - /// <summary> - /// Gets or sets What type the value should be interpreted as. - /// </summary> - public AXValueType Type { get; set; } - /// <summary> - /// Gets or sets Whether the value for this property is invalid. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? Invalid { get; set; } - /// <summary> - /// Gets or sets Reason for the value being invalid, if it is. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string InvalidReason { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXRelatedNode.cs b/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXRelatedNode.cs index b160514..986ccbd 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXRelatedNode.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXRelatedNode.cs @@ -22,6 +22,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Accessibility /// <summary> /// Gets or sets The text alternative of this node in the current context. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Text { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXValue.cs b/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXValue.cs index faa253e..d6a7050 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXValue.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXValue.cs @@ -20,19 +20,14 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Accessibility [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public object Value { get; set; } /// <summary> - /// Gets or sets The related node value, if any. + /// Gets or sets One or more related nodes, if applicable. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public AXRelatedNode RelatedNodeValue { get; set; } - /// <summary> - /// Gets or sets Multiple relted nodes, if applicable. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public AXRelatedNode[] RelatedNodeArrayValue { get; set; } + public AXRelatedNode[] RelatedNodes { get; set; } /// <summary> /// Gets or sets The sources which contributed to the computation of this property. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public AXPropertySource[] Sources { get; set; } + public AXValueSource[] Sources { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXValueSource.cs b/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXValueSource.cs index 5b207aa..7a87fc5 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXValueSource.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Accessibility/AXValueSource.cs @@ -17,34 +17,42 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Accessibility /// <summary> /// Gets or sets The value of this property source. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public AXValue Value { get; set; } /// <summary> /// Gets or sets The name of the relevant attribute, if any. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Attribute { get; set; } /// <summary> /// Gets or sets The value of the relevant attribute, if any. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public AXValue AttributeValue { get; set; } /// <summary> /// Gets or sets Whether this source is superseded by a higher priority source. /// </summary> - public bool Superseded { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? Superseded { get; set; } /// <summary> /// Gets or sets The native markup source for this value, e.g. a <label> element. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public AXValueNativeSourceType NativeSource { get; set; } /// <summary> /// Gets or sets The value, such as a node or node list, of the native source. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public AXValue NativeSourceValue { get; set; } /// <summary> /// Gets or sets Whether the value for this property is invalid. /// </summary> - public bool Invalid { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? Invalid { get; set; } /// <summary> /// Gets or sets Reason for the value being invalid, if it is. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string InvalidReason { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Accessibility/GetAXNodeCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/Accessibility/GetAXNodeCommandResponse.cs deleted file mode 100644 index e83341d..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Accessibility/GetAXNodeCommandResponse.cs +++ /dev/null @@ -1,20 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Accessibility -{ - /// <summary> - /// Fetches the accessibility node for this DOM node, if it exists. - /// </summary> - [CommandResponse(ProtocolName.Accessibility.GetAXNode)] - [SupportedBy("Chrome")] - public class GetAXNodeCommandResponse - { - /// <summary> - /// Gets or sets The <code>Accessibility.AXNode</code> for this DOM node, if it exists. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public AXNode AccessibilityNode { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Accessibility/GetPartialAXTreeCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Accessibility/GetPartialAXTreeCommand.cs index 09fa06d..dd0fd19 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Accessibility/GetPartialAXTreeCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Accessibility/GetPartialAXTreeCommand.cs @@ -18,6 +18,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Accessibility /// <summary> /// Gets or sets Whether to fetch this nodes ancestors, siblings and children. Defaults to true. /// </summary> - public bool FetchRelatives { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? FetchRelatives { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Animation/Animation.cs b/source/ChromeDevTools/Protocol/Chrome/Animation/Animation.cs index ad279c5..55c6090 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Animation/Animation.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Animation/Animation.cs @@ -49,6 +49,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Animation /// <summary> /// Gets or sets A unique ID for <code>Animation</code> representing the sources that triggered this CSS animation/transition. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string CssId { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationCanceledEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationCanceledEvent.cs index 72946b2..b87737b 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationCanceledEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationCanceledEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Animation { diff --git a/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationCreatedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationCreatedEvent.cs index a17aa70..dda0e61 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationCreatedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationCreatedEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Animation { diff --git a/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationPlayerCanceledEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationPlayerCanceledEvent.cs deleted file mode 100644 index 9371e78..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationPlayerCanceledEvent.cs +++ /dev/null @@ -1,17 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Animation -{ - /// <summary> - /// Event for AnimationPlayers in the frontend that have been cancelled. - /// </summary> - [Event(ProtocolName.Animation.AnimationPlayerCanceled)] - [SupportedBy("Chrome")] - public class AnimationPlayerCanceledEvent - { - /// <summary> - /// Gets or sets Id of the AnimationPlayer that was cancelled. - /// </summary> - public string PlayerId { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationPlayerCreatedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationPlayerCreatedEvent.cs deleted file mode 100644 index 4b29a0b..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationPlayerCreatedEvent.cs +++ /dev/null @@ -1,21 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Animation -{ - /// <summary> - /// Event for each animation player that has been created. - /// </summary> - [Event(ProtocolName.Animation.AnimationPlayerCreated)] - [SupportedBy("Chrome")] - public class AnimationPlayerCreatedEvent - { - /// <summary> - /// Gets or sets AnimationPlayer that was created. - /// </summary> - public AnimationPlayer Player { get; set; } - /// <summary> - /// Gets or sets Whether the timeline should be reset. - /// </summary> - public bool ResetTimeline { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationStartedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationStartedEvent.cs index 2df5c32..293a9bf 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationStartedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Animation/AnimationStartedEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Animation { diff --git a/source/ChromeDevTools/Protocol/Chrome/CSS/CSSKeyframeRule.cs b/source/ChromeDevTools/Protocol/Chrome/CSS/CSSKeyframeRule.cs index 2c36777..460ad6e 100644 --- a/source/ChromeDevTools/Protocol/Chrome/CSS/CSSKeyframeRule.cs +++ b/source/ChromeDevTools/Protocol/Chrome/CSS/CSSKeyframeRule.cs @@ -13,6 +13,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS /// <summary> /// Gets or sets The css style sheet identifier (absent for user agent stylesheet and user-specified stylesheet rules) this rule came from. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string StyleSheetId { get; set; } /// <summary> /// Gets or sets Parent stylesheet's origin. diff --git a/source/ChromeDevTools/Protocol/Chrome/CSS/CSSMedia.cs b/source/ChromeDevTools/Protocol/Chrome/CSS/CSSMedia.cs index 20f2a00..f532fe4 100644 --- a/source/ChromeDevTools/Protocol/Chrome/CSS/CSSMedia.cs +++ b/source/ChromeDevTools/Protocol/Chrome/CSS/CSSMedia.cs @@ -32,7 +32,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS /// Gets or sets Identifier of the stylesheet containing this object (if exists). /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string ParentStyleSheetId { get; set; } + public string StyleSheetId { get; set; } /// <summary> /// Gets or sets Array of media queries. /// </summary> diff --git a/source/ChromeDevTools/Protocol/Chrome/CSS/FontsUpdatedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/CSS/FontsUpdatedEvent.cs index 3f98771..cf9505a 100644 --- a/source/ChromeDevTools/Protocol/Chrome/CSS/FontsUpdatedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/CSS/FontsUpdatedEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS { diff --git a/source/ChromeDevTools/Protocol/Chrome/CSS/GetBackgroundColorsCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/CSS/GetBackgroundColorsCommandResponse.cs index 7af43ac..acae413 100644 --- a/source/ChromeDevTools/Protocol/Chrome/CSS/GetBackgroundColorsCommandResponse.cs +++ b/source/ChromeDevTools/Protocol/Chrome/CSS/GetBackgroundColorsCommandResponse.cs @@ -11,6 +11,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS /// <summary> /// Gets or sets The range of background colors behind this element, if it contains any visible text. If no visible text is present, this will be undefined. In the case of a flat background color, this will consist of simply that color. In the case of a gradient, this will consist of each of the color stops. For anything more complicated, this will be an empty array. Images will be ignored (as if the image had failed to load). /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string[] BackgroundColors { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/CSS/GetMatchedStylesForNodeCommand.cs b/source/ChromeDevTools/Protocol/Chrome/CSS/GetMatchedStylesForNodeCommand.cs index 315b825..b5a69f7 100644 --- a/source/ChromeDevTools/Protocol/Chrome/CSS/GetMatchedStylesForNodeCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/CSS/GetMatchedStylesForNodeCommand.cs @@ -15,15 +15,5 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS /// Gets or sets NodeId /// </summary> public long NodeId { get; set; } - /// <summary> - /// Gets or sets Whether to exclude pseudo styles (default: false). - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? ExcludePseudo { get; set; } - /// <summary> - /// Gets or sets Whether to exclude inherited styles (default: false). - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? ExcludeInherited { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/CSS/GetMatchedStylesForNodeCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/CSS/GetMatchedStylesForNodeCommandResponse.cs index be70f68..5b57feb 100644 --- a/source/ChromeDevTools/Protocol/Chrome/CSS/GetMatchedStylesForNodeCommandResponse.cs +++ b/source/ChromeDevTools/Protocol/Chrome/CSS/GetMatchedStylesForNodeCommandResponse.cs @@ -11,6 +11,16 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS [SupportedBy("Chrome")] public class GetMatchedStylesForNodeCommandResponse { + /// <summary> + /// Gets or sets Inline style for the specified DOM node. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public CSSStyle InlineStyle { get; set; } + /// <summary> + /// Gets or sets Attribute-defined element style (e.g. resulting from "width=20 height=100%"). + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public CSSStyle AttributesStyle { get; set; } /// <summary> /// Gets or sets CSS rules matching this node, from all applicable stylesheets. /// </summary> @@ -20,11 +30,16 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS /// Gets or sets Pseudo style matches for this node. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public PseudoIdMatches[] PseudoElements { get; set; } + public PseudoElementMatches[] PseudoElements { get; set; } /// <summary> /// Gets or sets A chain of inherited styles (from the immediate node parent up to the DOM tree root). /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public InheritedStyleEntry[] Inherited { get; set; } + /// <summary> + /// Gets or sets A list of CSS keyframed animations matching this node. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public CSSKeyframesRule[] CssKeyframesRules { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/CSS/LayoutTreeNode.cs b/source/ChromeDevTools/Protocol/Chrome/CSS/LayoutTreeNode.cs index 3cff9d1..49bb322 100644 --- a/source/ChromeDevTools/Protocol/Chrome/CSS/LayoutTreeNode.cs +++ b/source/ChromeDevTools/Protocol/Chrome/CSS/LayoutTreeNode.cs @@ -21,14 +21,17 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS /// <summary> /// Gets or sets Contents of the LayoutText if any /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string LayoutText { get; set; } /// <summary> /// Gets or sets The post layout inline text nodes, if any. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public InlineTextBox[] InlineTextNodes { get; set; } /// <summary> /// Gets or sets Index into the computedStyles array returned by getLayoutTreeAndStyles. /// </summary> - public long StyleIndex { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? StyleIndex { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/CSS/SetStyleSheetTextCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/CSS/SetStyleSheetTextCommandResponse.cs index 7c57906..9ee94e0 100644 --- a/source/ChromeDevTools/Protocol/Chrome/CSS/SetStyleSheetTextCommandResponse.cs +++ b/source/ChromeDevTools/Protocol/Chrome/CSS/SetStyleSheetTextCommandResponse.cs @@ -14,6 +14,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS /// <summary> /// Gets or sets URL of source map associated with script (if any). /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string SourceMapURL { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/CSS/ShorthandEntry.cs b/source/ChromeDevTools/Protocol/Chrome/CSS/ShorthandEntry.cs index 1563402..dd9c49c 100644 --- a/source/ChromeDevTools/Protocol/Chrome/CSS/ShorthandEntry.cs +++ b/source/ChromeDevTools/Protocol/Chrome/CSS/ShorthandEntry.cs @@ -21,6 +21,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.CSS /// <summary> /// Gets or sets Whether the property has "!important" annotation (implies <code>false</code> if absent). /// </summary> - public bool Important { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? Important { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Canvas/Call.cs b/source/ChromeDevTools/Protocol/Chrome/Canvas/Call.cs deleted file mode 100644 index 71d72db..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Canvas/Call.cs +++ /dev/null @@ -1,68 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas -{ - /// <summary> - /// - /// </summary> - [SupportedBy("Chrome")] - public class Call - { - /// <summary> - /// Gets or sets ContextId - /// </summary> - public string ContextId { get; set; } - /// <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> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? IsDrawingCall { get; set; } - /// <summary> - /// Gets or sets IsFrameEndCall - /// </summary> - [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> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public long? LineNumber { get; set; } - /// <summary> - /// Gets or sets ColumnNumber - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public long? ColumnNumber { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Canvas/CallArgument.cs b/source/ChromeDevTools/Protocol/Chrome/Canvas/CallArgument.cs deleted file mode 100644 index 4275208..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Canvas/CallArgument.cs +++ /dev/null @@ -1,43 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas -{ - /// <summary> - /// - /// </summary> - [SupportedBy("Chrome")] - public class CallArgument - { - /// <summary> - /// Gets or sets String representation of the object. - /// </summary> - public string Description { get; set; } - /// <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; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Canvas/CaptureFrameCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Canvas/CaptureFrameCommand.cs deleted file mode 100644 index 6ffc545..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Canvas/CaptureFrameCommand.cs +++ /dev/null @@ -1,20 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas -{ - /// <summary> - /// Starts (or continues) a canvas frame capturing which will be stopped automatically after the next frame is prepared. - /// </summary> - [Command(ProtocolName.Canvas.CaptureFrame)] - [SupportedBy("Chrome")] - public class CaptureFrameCommand - { - /// <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; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Canvas/ContextCreatedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Canvas/ContextCreatedEvent.cs deleted file mode 100644 index 388fcf8..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Canvas/ContextCreatedEvent.cs +++ /dev/null @@ -1,17 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas -{ - /// <summary> - /// Fired when a canvas context has been created in the given frame. The context may not be instrumented (see hasUninstrumentedCanvases command). - /// </summary> - [Event(ProtocolName.Canvas.ContextCreated)] - [SupportedBy("Chrome")] - public class ContextCreatedEvent - { - /// <summary> - /// Gets or sets Identifier of the frame containing a canvas with a context. - /// </summary> - public string FrameId { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Canvas/EvaluateTraceLogCallArgumentCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Canvas/EvaluateTraceLogCallArgumentCommand.cs deleted file mode 100644 index 0e96090..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Canvas/EvaluateTraceLogCallArgumentCommand.cs +++ /dev/null @@ -1,32 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas -{ - /// <summary> - /// Evaluates a given trace call argument or its result. - /// </summary> - [Command(ProtocolName.Canvas.EvaluateTraceLogCallArgument)] - [SupportedBy("Chrome")] - public class EvaluateTraceLogCallArgumentCommand - { - /// <summary> - /// Gets or sets TraceLogId - /// </summary> - public string TraceLogId { get; set; } - /// <summary> - /// Gets or sets Index of the call to evaluate on (zero based). - /// </summary> - public long CallIndex { get; set; } - /// <summary> - /// Gets or sets Index of the argument to evaluate (zero based). Provide <code>-1</code> to evaluate call result. - /// </summary> - public long ArgumentIndex { get; set; } - /// <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; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Canvas/EvaluateTraceLogCallArgumentCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/Canvas/EvaluateTraceLogCallArgumentCommandResponse.cs deleted file mode 100644 index da274cc..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Canvas/EvaluateTraceLogCallArgumentCommandResponse.cs +++ /dev/null @@ -1,25 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas -{ - /// <summary> - /// Evaluates a given trace call argument or its result. - /// </summary> - [CommandResponse(ProtocolName.Canvas.EvaluateTraceLogCallArgument)] - [SupportedBy("Chrome")] - public class EvaluateTraceLogCallArgumentCommandResponse - { - /// <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; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Canvas/GetTraceLogCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Canvas/GetTraceLogCommand.cs deleted file mode 100644 index de96338..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Canvas/GetTraceLogCommand.cs +++ /dev/null @@ -1,26 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas -{ - [Command(ProtocolName.Canvas.GetTraceLog)] - [SupportedBy("Chrome")] - public class GetTraceLogCommand - { - /// <summary> - /// Gets or sets TraceLogId - /// </summary> - public string TraceLogId { get; set; } - /// <summary> - /// Gets or sets StartOffset - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public long? StartOffset { get; set; } - /// <summary> - /// Gets or sets MaxLength - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public long? MaxLength { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Canvas/ResourceState.cs b/source/ChromeDevTools/Protocol/Chrome/Canvas/ResourceState.cs deleted file mode 100644 index 37d4589..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Canvas/ResourceState.cs +++ /dev/null @@ -1,32 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas -{ - /// <summary> - /// Resource state. - /// </summary> - [SupportedBy("Chrome")] - public class ResourceState - { - /// <summary> - /// Gets or sets Id - /// </summary> - public string Id { get; set; } - /// <summary> - /// Gets or sets TraceLogId - /// </summary> - public string TraceLogId { get; set; } - /// <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; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Canvas/ResourceStateDescriptor.cs b/source/ChromeDevTools/Protocol/Chrome/Canvas/ResourceStateDescriptor.cs deleted file mode 100644 index 7b9ca5c..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Canvas/ResourceStateDescriptor.cs +++ /dev/null @@ -1,38 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas -{ - /// <summary> - /// Resource state descriptor. - /// </summary> - [SupportedBy("Chrome")] - public class ResourceStateDescriptor - { - /// <summary> - /// Gets or sets State name. - /// </summary> - public string Name { get; set; } - /// <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> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? IsArray { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Canvas/StartCapturingCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Canvas/StartCapturingCommand.cs deleted file mode 100644 index f898829..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Canvas/StartCapturingCommand.cs +++ /dev/null @@ -1,20 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas -{ - /// <summary> - /// Starts (or continues) consecutive canvas frames capturing. The capturing is stopped by the corresponding stopCapturing command. - /// </summary> - [Command(ProtocolName.Canvas.StartCapturing)] - [SupportedBy("Chrome")] - public class StartCapturingCommand - { - /// <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; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Canvas/TraceLogsRemovedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Canvas/TraceLogsRemovedEvent.cs deleted file mode 100644 index be7e727..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Canvas/TraceLogsRemovedEvent.cs +++ /dev/null @@ -1,23 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Canvas -{ - /// <summary> - /// Fired when a set of trace logs were removed from the backend. If no parameters are given, all trace logs were removed. - /// </summary> - [Event(ProtocolName.Canvas.TraceLogsRemoved)] - [SupportedBy("Chrome")] - public class TraceLogsRemovedEvent - { - /// <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; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Console/AsyncStackTrace.cs b/source/ChromeDevTools/Protocol/Chrome/Console/AsyncStackTrace.cs deleted file mode 100644 index 6bc8dbc..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Console/AsyncStackTrace.cs +++ /dev/null @@ -1,28 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Console -{ - /// <summary> - /// Asynchronous JavaScript call stack. - /// </summary> - [SupportedBy("Chrome")] - public class AsyncStackTrace - { - /// <summary> - /// Gets or sets Call frames of the stack trace. - /// </summary> - public CallFrame[] CallFrames { get; set; } - /// <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. - /// </summary> - [JsonProperty("asyncStackTrace")] - public AsyncStackTrace AsyncStackTraceChild { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Console/ConsoleMessage.cs b/source/ChromeDevTools/Protocol/Chrome/Console/ConsoleMessage.cs index 4ea7548..659878d 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Console/ConsoleMessage.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Console/ConsoleMessage.cs @@ -23,63 +23,19 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Console /// </summary> public string Text { get; set; } /// <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. + /// Gets or sets Line number in the resource that generated this message (1-based). /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public long? Line { get; set; } /// <summary> - /// Gets or sets Column number in the resource that generated this message. + /// Gets or sets Column number in the resource that generated this message (1-based). /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public long? Column { get; set; } - /// <summary> - /// Gets or sets Repeat count for repeated messages. - /// </summary> - [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. - /// </summary> - public double Timestamp { get; set; } - /// <summary> - /// Gets or sets Identifier of the context where this message was created - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public long? ExecutionContextId { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Console/MessageRepeatCountUpdatedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Console/MessageRepeatCountUpdatedEvent.cs deleted file mode 100644 index e608bce..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Console/MessageRepeatCountUpdatedEvent.cs +++ /dev/null @@ -1,21 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Console -{ - /// <summary> - /// Is not issued. Will be gone in the future versions of the protocol. - /// </summary> - [Event(ProtocolName.Console.MessageRepeatCountUpdated)] - [SupportedBy("Chrome")] - public class MessageRepeatCountUpdatedEvent - { - /// <summary> - /// Gets or sets New repeat count value. - /// </summary> - public long Count { get; set; } - /// <summary> - /// Gets or sets Timestamp of most recent message in batch. - /// </summary> - public double Timestamp { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Console/MessagesClearedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Console/MessagesClearedEvent.cs deleted file mode 100644 index 3116648..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Console/MessagesClearedEvent.cs +++ /dev/null @@ -1,13 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Console -{ - /// <summary> - /// Issued when console is cleared. This happens either upon <code>clearMessages</code> command or after page navigation. - /// </summary> - [Event(ProtocolName.Console.MessagesCleared)] - [SupportedBy("Chrome")] - public class MessagesClearedEvent - { - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/DOM/EventListener.cs b/source/ChromeDevTools/Protocol/Chrome/DOM/EventListener.cs deleted file mode 100644 index 83ddbf5..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/DOM/EventListener.cs +++ /dev/null @@ -1,39 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.DOM -{ - /// <summary> - /// DOM interaction is implemented in terms of mirror objects that represent the actual DOM nodes. DOMNode is a base node mirror type. - /// </summary> - [SupportedBy("Chrome")] - public class EventListener - { - /// <summary> - /// Gets or sets <code>EventListener</code>'s type. - /// </summary> - public string Type { get; set; } - /// <summary> - /// Gets or sets <code>EventListener</code>'s useCapture. - /// </summary> - public bool UseCapture { get; set; } - /// <summary> - /// Gets or sets <code>EventListener</code>'s isAttribute. - /// </summary> - public bool IsAttribute { get; set; } - /// <summary> - /// Gets or sets Target <code>DOMNode</code> id. - /// </summary> - public long NodeId { get; set; } - /// <summary> - /// Gets or sets Handler code location. - /// </summary> - public Debugger.Location Location { get; set; } - /// <summary> - /// Gets or sets Event handler function value. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Runtime.RemoteObject Handler { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/DOM/GetDocumentCommand.cs b/source/ChromeDevTools/Protocol/Chrome/DOM/GetDocumentCommand.cs index 66c92b6..ad40297 100644 --- a/source/ChromeDevTools/Protocol/Chrome/DOM/GetDocumentCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/DOM/GetDocumentCommand.cs @@ -14,10 +14,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.DOM /// <summary> /// Gets or sets The maximum depth at which children should be retrieved, defaults to 1. Use -1 for the entire subtree or provide an integer larger than 0. /// </summary> - public long Depth { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? Depth { get; set; } /// <summary> /// Gets or sets Whether or not iframes and shadow roots should be traversed when returning the subtree (default is false). /// </summary> - public bool Pierce { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? Pierce { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/DOM/GetEventListenersForNodeCommand.cs b/source/ChromeDevTools/Protocol/Chrome/DOM/GetEventListenersForNodeCommand.cs deleted file mode 100644 index b717a8a..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/DOM/GetEventListenersForNodeCommand.cs +++ /dev/null @@ -1,24 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.DOM -{ - /// <summary> - /// Returns event listeners relevant to the node. - /// </summary> - [Command(ProtocolName.DOM.GetEventListenersForNode)] - [SupportedBy("Chrome")] - public class GetEventListenersForNodeCommand - { - /// <summary> - /// Gets or sets Id of the node to get listeners for. - /// </summary> - public long NodeId { get; set; } - /// <summary> - /// Gets or sets Symbolic group name for handler value. Handler value is not returned without this parameter specified. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string ObjectGroup { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/DOM/GetFlattenedDocumentCommand.cs b/source/ChromeDevTools/Protocol/Chrome/DOM/GetFlattenedDocumentCommand.cs index 4d0b7d4..b098415 100644 --- a/source/ChromeDevTools/Protocol/Chrome/DOM/GetFlattenedDocumentCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/DOM/GetFlattenedDocumentCommand.cs @@ -14,10 +14,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.DOM /// <summary> /// Gets or sets The maximum depth at which children should be retrieved, defaults to 1. Use -1 for the entire subtree or provide an integer larger than 0. /// </summary> - public long Depth { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? Depth { get; set; } /// <summary> /// Gets or sets Whether or not iframes and shadow roots should be traversed when returning the subtree (default is false). /// </summary> - public bool Pierce { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? Pierce { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/DOM/HighlightConfig.cs b/source/ChromeDevTools/Protocol/Chrome/DOM/HighlightConfig.cs index c7e1bba..48dfb8a 100644 --- a/source/ChromeDevTools/Protocol/Chrome/DOM/HighlightConfig.cs +++ b/source/ChromeDevTools/Protocol/Chrome/DOM/HighlightConfig.cs @@ -28,7 +28,8 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.DOM /// <summary> /// Gets or sets DisplayAsMaterial /// </summary> - public bool DisplayAsMaterial { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? DisplayAsMaterial { get; set; } /// <summary> /// Gets or sets The content box highlight fill color (default: transparent). /// </summary> @@ -67,6 +68,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.DOM /// <summary> /// Gets or sets Selectors to highlight relevant nodes. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string SelectorList { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/DOM/Node.cs b/source/ChromeDevTools/Protocol/Chrome/DOM/Node.cs index bec244e..74fdff1 100644 --- a/source/ChromeDevTools/Protocol/Chrome/DOM/Node.cs +++ b/source/ChromeDevTools/Protocol/Chrome/DOM/Node.cs @@ -17,7 +17,8 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.DOM /// <summary> /// Gets or sets The id of the parent node if any. /// </summary> - public long ParentId { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? ParentId { get; set; } /// <summary> /// Gets or sets The BackendNodeId for this node. /// </summary> @@ -141,6 +142,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.DOM /// <summary> /// Gets or sets Whether the node is SVG. /// </summary> - public bool IsSVG { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? IsSVG { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/DOM/NodeHighlightRequestedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/DOM/NodeHighlightRequestedEvent.cs index 40e59d0..de433c2 100644 --- a/source/ChromeDevTools/Protocol/Chrome/DOM/NodeHighlightRequestedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/DOM/NodeHighlightRequestedEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.DOM { diff --git a/source/ChromeDevTools/Protocol/Chrome/DOM/RequestChildNodesCommand.cs b/source/ChromeDevTools/Protocol/Chrome/DOM/RequestChildNodesCommand.cs index 9d526fa..623161c 100644 --- a/source/ChromeDevTools/Protocol/Chrome/DOM/RequestChildNodesCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/DOM/RequestChildNodesCommand.cs @@ -20,5 +20,10 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.DOM /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public long? Depth { get; set; } + /// <summary> + /// Gets or sets Whether or not iframes and shadow roots should be traversed when returning the sub-tree (default is false). + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? Pierce { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/DOM/SetInspectModeCommand.cs b/source/ChromeDevTools/Protocol/Chrome/DOM/SetInspectModeCommand.cs index adeb99e..70a3c7e 100644 --- a/source/ChromeDevTools/Protocol/Chrome/DOM/SetInspectModeCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/DOM/SetInspectModeCommand.cs @@ -7,19 +7,14 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.DOM /// <summary> /// Enters the 'inspect' mode. In this mode, elements that user is hovering over are highlighted. Backend then generates 'inspectNodeRequested' event upon element selection. /// </summary> - [Command(ProtocolName.DOM.SetInspectModeEnabled)] + [Command(ProtocolName.DOM.SetInspectMode)] [SupportedBy("Chrome")] - public class SetInspectModeEnabledCommand + public class SetInspectModeCommand { /// <summary> - /// Gets or sets True to enable inspection mode, false to disable it. + /// Gets or sets Set an inspection mode. /// </summary> - public bool Enabled { get; set; } - /// <summary> - /// Gets or sets True to enable inspection mode for user agent shadow DOM. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? InspectUAShadowDOM { get; set; } + public string Mode { get; set; } /// <summary> /// Gets or sets A descriptor for the highlight appearance of hovered-over nodes. May be omitted if <code>enabled == false</code>. /// </summary> diff --git a/source/ChromeDevTools/Protocol/Chrome/DOMDebugger/EventListener.cs b/source/ChromeDevTools/Protocol/Chrome/DOMDebugger/EventListener.cs index b8299ee..3070f1a 100644 --- a/source/ChromeDevTools/Protocol/Chrome/DOMDebugger/EventListener.cs +++ b/source/ChromeDevTools/Protocol/Chrome/DOMDebugger/EventListener.cs @@ -41,14 +41,17 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.DOMDebugger /// <summary> /// Gets or sets Event handler function value. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public Runtime.RemoteObject Handler { get; set; } /// <summary> /// Gets or sets Event original handler function value. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public Runtime.RemoteObject OriginalHandler { get; set; } /// <summary> /// Gets or sets Node the listener is added to (if any). /// </summary> - public long BackendNodeId { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? BackendNodeId { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/DOMDebugger/GetEventListenersCommand.cs b/source/ChromeDevTools/Protocol/Chrome/DOMDebugger/GetEventListenersCommand.cs index 46975a3..353df4c 100644 --- a/source/ChromeDevTools/Protocol/Chrome/DOMDebugger/GetEventListenersCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/DOMDebugger/GetEventListenersCommand.cs @@ -18,10 +18,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.DOMDebugger /// <summary> /// Gets or sets The maximum depth at which Node children should be retrieved, defaults to 1. Use -1 for the entire subtree or provide an integer larger than 0. /// </summary> - public long Depth { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? Depth { get; set; } /// <summary> /// Gets or sets Whether or not iframes and shadow roots should be traversed when returning the subtree (default is false). Reports listeners for all contexts if pierce is enabled. /// </summary> - public bool Pierce { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? Pierce { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/AsyncOperation.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/AsyncOperation.cs deleted file mode 100644 index 95db90d..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/AsyncOperation.cs +++ /dev/null @@ -1,32 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Information about the async operation. - /// </summary> - [SupportedBy("Chrome")] - public class AsyncOperation - { - /// <summary> - /// Gets or sets Unique id of the async operation. - /// </summary> - public long Id { get; set; } - /// <summary> - /// Gets or sets String description of the async operation. - /// </summary> - public string Description { get; set; } - /// <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; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/AsyncOperationCompletedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/AsyncOperationCompletedEvent.cs deleted file mode 100644 index 5c4c61d..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/AsyncOperationCompletedEvent.cs +++ /dev/null @@ -1,17 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Fired when an async operation is completed (while in a debugger stepping session). - /// </summary> - [Event(ProtocolName.Debugger.AsyncOperationCompleted)] - [SupportedBy("Chrome")] - public class AsyncOperationCompletedEvent - { - /// <summary> - /// Gets or sets ID of the async operation that was completed. - /// </summary> - public long Id { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/AsyncOperationStartedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/AsyncOperationStartedEvent.cs deleted file mode 100644 index d108ab4..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/AsyncOperationStartedEvent.cs +++ /dev/null @@ -1,17 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Fired when an async operation is scheduled (while in a debugger stepping session). - /// </summary> - [Event(ProtocolName.Debugger.AsyncOperationStarted)] - [SupportedBy("Chrome")] - public class AsyncOperationStartedEvent - { - /// <summary> - /// Gets or sets Information about the async operation. - /// </summary> - public AsyncOperation Operation { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/BreakLocation.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/BreakLocation.cs index 2f8067a..73f4131 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/BreakLocation.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Debugger/BreakLocation.cs @@ -21,10 +21,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger /// <summary> /// Gets or sets Column number in the script (0-based). /// </summary> - public long ColumnNumber { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? ColumnNumber { get; set; } /// <summary> /// Gets or sets Type /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Type { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/ContinueToLocationCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/ContinueToLocationCommand.cs index 642c31f..d9150fa 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/ContinueToLocationCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Debugger/ContinueToLocationCommand.cs @@ -15,10 +15,5 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger /// Gets or sets Location to continue to. /// </summary> public Location Location { get; set; } - /// <summary> - /// Gets or sets Allows breakpoints at the intemediate positions inside statements. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? InterstatementLocation { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/EnablePromiseTrackerCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/EnablePromiseTrackerCommand.cs deleted file mode 100644 index 9fa809a..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/EnablePromiseTrackerCommand.cs +++ /dev/null @@ -1,20 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Enables promise tracking, information about <code>Promise</code>s created or updated will now be stored on the backend. - /// </summary> - [Command(ProtocolName.Debugger.EnablePromiseTracker)] - [SupportedBy("Chrome")] - public class EnablePromiseTrackerCommand - { - /// <summary> - /// Gets or sets Whether to capture stack traces for promise creation and settlement events (default: false). - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? CaptureStacks { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/EvaluateOnCallFrameCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/EvaluateOnCallFrameCommand.cs index 4f23eb2..c2baf27 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/EvaluateOnCallFrameCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Debugger/EvaluateOnCallFrameCommand.cs @@ -30,10 +30,10 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger [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. + /// Gets or sets In silent mode exceptions thrown during evaluation are not reported and do not pause execution. Overrides <code>setPauseOnException</code> state. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? DoNotPauseOnExceptionsAndMuteConsole { get; set; } + public bool? Silent { get; set; } /// <summary> /// Gets or sets Whether the result is expected to be a JSON object that should be sent by value. /// </summary> @@ -44,5 +44,10 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public bool? GeneratePreview { get; set; } + /// <summary> + /// Gets or sets Whether to throw an exception if side effect cannot be ruled out during evaluation. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? ThrowOnSideEffect { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/EvaluateOnCallFrameCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/EvaluateOnCallFrameCommandResponse.cs index 7f7f766..018f9ce 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/EvaluateOnCallFrameCommandResponse.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Debugger/EvaluateOnCallFrameCommandResponse.cs @@ -16,14 +16,9 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger /// </summary> public Runtime.RemoteObject Result { get; set; } /// <summary> - /// Gets or sets True if the result was thrown during the evaluation. - /// </summary> - [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; } + public Runtime.ExceptionDetails ExceptionDetails { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/ExceptionDetails.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/ExceptionDetails.cs deleted file mode 100644 index b481d2a..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/ExceptionDetails.cs +++ /dev/null @@ -1,43 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Detailed information on exception (or error) that was thrown during script compilation or execution. - /// </summary> - [SupportedBy("Chrome")] - public class ExceptionDetails - { - /// <summary> - /// Gets or sets Exception text. - /// </summary> - public string Text { 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 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> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public long? Line { get; set; } - /// <summary> - /// Gets or sets Column number in the resource that generated this message. - /// </summary> - [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; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/FunctionDetails.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/FunctionDetails.cs deleted file mode 100644 index eb6b876..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/FunctionDetails.cs +++ /dev/null @@ -1,32 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Information about the function. - /// </summary> - [SupportedBy("Chrome")] - public class FunctionDetails - { - /// <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. - /// </summary> - public string FunctionName { get; set; } - /// <summary> - /// Gets or sets Whether this is a generator function. - /// </summary> - public bool IsGenerator { get; set; } - /// <summary> - /// Gets or sets Scope chain for this closure. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Scope[] ScopeChain { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/GeneratorObjectDetails.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/GeneratorObjectDetails.cs deleted file mode 100644 index 7e7f00e..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/GeneratorObjectDetails.cs +++ /dev/null @@ -1,31 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Information about the generator object. - /// </summary> - [SupportedBy("Chrome")] - public class GeneratorObjectDetails - { - /// <summary> - /// Gets or sets Generator function. - /// </summary> - public Runtime.RemoteObject Function { get; set; } - /// <summary> - /// Gets or sets Name of the generator function. - /// </summary> - public string FunctionName { get; set; } - /// <summary> - /// Gets or sets Current generator object status. - /// </summary> - public string Status { get; set; } - /// <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; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/GetBacktraceCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/GetBacktraceCommandResponse.cs deleted file mode 100644 index 56d99cb..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/GetBacktraceCommandResponse.cs +++ /dev/null @@ -1,24 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Returns call stack including variables changed since VM was paused. VM must be paused. - /// </summary> - [CommandResponse(ProtocolName.Debugger.GetBacktrace)] - [SupportedBy("Chrome")] - public class GetBacktraceCommandResponse - { - /// <summary> - /// Gets or sets Call stack the virtual machine stopped on. - /// </summary> - public CallFrame[] CallFrames { get; set; } - /// <summary> - /// Gets or sets Async stack trace, if any. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public StackTrace AsyncStackTrace { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/GetPossibleBreakpointsCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/GetPossibleBreakpointsCommand.cs index 17cf115..2d14038 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/GetPossibleBreakpointsCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Debugger/GetPossibleBreakpointsCommand.cs @@ -18,10 +18,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger /// <summary> /// Gets or sets End of range to search possible breakpoint locations in (excluding). When not specifed, end of scripts is used as end of range. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public Location End { get; set; } /// <summary> /// Gets or sets Only consider locations which are in the same (non-nested) function as start. /// </summary> - public bool RestrictToFunction { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? RestrictToFunction { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/GetPromiseByIdCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/GetPromiseByIdCommand.cs deleted file mode 100644 index 06135f8..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/GetPromiseByIdCommand.cs +++ /dev/null @@ -1,24 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Returns <code>Promise</code> with specified ID. - /// </summary> - [Command(ProtocolName.Debugger.GetPromiseById)] - [SupportedBy("Chrome")] - public class GetPromiseByIdCommand - { - /// <summary> - /// Gets or sets PromiseId - /// </summary> - public long PromiseId { get; set; } - /// <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; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/GetStepInPositionsCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/GetStepInPositionsCommandResponse.cs deleted file mode 100644 index 80d6719..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/GetStepInPositionsCommandResponse.cs +++ /dev/null @@ -1,20 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Lists all positions where step-in is possible for a current statement in a specified call frame - /// </summary> - [CommandResponse(ProtocolName.Debugger.GetStepInPositions)] - [SupportedBy("Chrome")] - public class GetStepInPositionsCommandResponse - { - /// <summary> - /// Gets or sets experimental - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Location[] StepInPositions { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/GlobalObjectClearedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/GlobalObjectClearedEvent.cs deleted file mode 100644 index 25a4e37..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/GlobalObjectClearedEvent.cs +++ /dev/null @@ -1,13 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Called when global has been cleared and debugger client should reset its state. Happens upon navigation or reload. - /// </summary> - [Event(ProtocolName.Debugger.GlobalObjectCleared)] - [SupportedBy("Chrome")] - public class GlobalObjectClearedEvent - { - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/PausedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/PausedEvent.cs index 8f17fb5..fc7d6cb 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/PausedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Debugger/PausedEvent.cs @@ -31,6 +31,6 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger /// Gets or sets Async stack trace, if any. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public StackTrace AsyncStackTrace { get; set; } + public Runtime.StackTrace AsyncStackTrace { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/PromiseDetails.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/PromiseDetails.cs deleted file mode 100644 index 311ccf3..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/PromiseDetails.cs +++ /dev/null @@ -1,62 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Information about the promise. - /// </summary> - [SupportedBy("Chrome")] - public class PromiseDetails - { - /// <summary> - /// Gets or sets Unique id of the promise. - /// </summary> - public long Id { get; set; } - /// <summary> - /// Gets or sets Status of the promise. - /// </summary> - public string Status { get; set; } - /// <summary> - /// Gets or sets Id of the parent promise. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public long? ParentId { get; set; } - /// <summary> - /// Gets or sets Top call frame on promise creation. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Console.CallFrame CallFrame { get; set; } - /// <summary> - /// Gets or sets Creation time of the promise. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public double CreationTime { get; set; } - /// <summary> - /// Gets or sets Settlement time of the promise. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public double SettlementTime { get; set; } - /// <summary> - /// Gets or sets JavaScript stack trace on promise creation. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Console.CallFrame[] CreationStack { get; set; } - /// <summary> - /// Gets or sets JavaScript asynchronous stack trace on promise creation, if available. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Console.AsyncStackTrace AsyncCreationStack { get; set; } - /// <summary> - /// Gets or sets JavaScript stack trace on promise settlement. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Console.CallFrame[] SettlementStack { get; set; } - /// <summary> - /// Gets or sets JavaScript asynchronous stack trace on promise settlement, if available. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Console.AsyncStackTrace AsyncSettlementStack { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/PromiseUpdatedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/PromiseUpdatedEvent.cs deleted file mode 100644 index 6bb1d8f..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/PromiseUpdatedEvent.cs +++ /dev/null @@ -1,21 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Fired when a <code>Promise</code> is created, updated or garbage collected. - /// </summary> - [Event(ProtocolName.Debugger.PromiseUpdated)] - [SupportedBy("Chrome")] - public class PromiseUpdatedEvent - { - /// <summary> - /// Gets or sets Type of the event. - /// </summary> - public string EventType { get; set; } - /// <summary> - /// Gets or sets Information about the updated <code>Promise</code>. - /// </summary> - public PromiseDetails Promise { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/RestartFrameCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/RestartFrameCommandResponse.cs index 3df7b7b..8d62108 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/RestartFrameCommandResponse.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Debugger/RestartFrameCommandResponse.cs @@ -16,13 +16,9 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger /// </summary> public CallFrame[] CallFrames { get; set; } /// <summary> - /// Gets or sets VM-specific description. - /// </summary> - public object Result { get; set; } - /// <summary> /// Gets or sets Async stack trace, if any. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public StackTrace AsyncStackTrace { get; set; } + public Runtime.StackTrace AsyncStackTrace { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/RunScriptCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/RunScriptCommand.cs deleted file mode 100644 index 5c786b7..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/RunScriptCommand.cs +++ /dev/null @@ -1,34 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Runs script with given id in a given context. - /// </summary> - [Command(ProtocolName.Debugger.RunScript)] - [SupportedBy("Chrome")] - public class RunScriptCommand - { - /// <summary> - /// Gets or sets Id of the script to run. - /// </summary> - public string ScriptId { get; set; } - /// <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> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public long? ExecutionContextId { get; set; } - /// <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; } - /// <summary> - /// Gets or sets Specifies whether script run should stop on exceptions and mute console. Overrides setPauseOnException state. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? DoNotPauseOnExceptionsAndMuteConsole { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/Scope.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/Scope.cs index 7ade59b..45f6ebc 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/Scope.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Debugger/Scope.cs @@ -21,14 +21,17 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger /// <summary> /// Gets or sets Name /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Name { get; set; } /// <summary> /// Gets or sets Location in the source code where scope starts /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public Location StartLocation { get; set; } /// <summary> /// Gets or sets Location in the source code where scope ends /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public Location EndLocation { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/ScriptFailedToParseEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/ScriptFailedToParseEvent.cs index e963b42..b5408fa 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/ScriptFailedToParseEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Debugger/ScriptFailedToParseEvent.cs @@ -34,15 +34,18 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger /// </summary> public long EndColumn { get; set; } /// <summary> - /// Gets or sets Determines whether this script is a user extension script. + /// Gets or sets Specifies script creation context. /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? IsContentScript { get; set; } + public long ExecutionContextId { get; set; } + /// <summary> + /// Gets or sets Content hash of the script. + /// </summary> + public string Hash { get; set; } /// <summary> - /// Gets or sets Determines whether this script is an internal script. + /// Gets or sets Embedder-specific auxiliary data. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? IsInternalScript { get; set; } + public object ExecutionContextAuxData { get; set; } /// <summary> /// Gets or sets URL of source map associated with script (if any). /// </summary> @@ -53,5 +56,15 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public bool? HasSourceURL { get; set; } + /// <summary> + /// Gets or sets True, if this script is ES6 module. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? IsModule { get; set; } + /// <summary> + /// Gets or sets This script length. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? Length { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/ScriptParsedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/ScriptParsedEvent.cs index bb53716..5cfcc01 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/ScriptParsedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Debugger/ScriptParsedEvent.cs @@ -34,15 +34,23 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger /// </summary> public long EndColumn { get; set; } /// <summary> - /// Gets or sets Determines whether this script is a user extension script. + /// Gets or sets Specifies script creation context. + /// </summary> + public long ExecutionContextId { get; set; } + /// <summary> + /// Gets or sets Content hash of the script. + /// </summary> + public string Hash { get; set; } + /// <summary> + /// Gets or sets Embedder-specific auxiliary data. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? IsContentScript { get; set; } + public object ExecutionContextAuxData { get; set; } /// <summary> - /// Gets or sets Determines whether this script is an internal script. + /// Gets or sets True, if this script is generated as a result of the live edit operation. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? IsInternalScript { get; set; } + public bool? IsLiveEdit { get; set; } /// <summary> /// Gets or sets URL of source map associated with script (if any). /// </summary> @@ -53,5 +61,15 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public bool? HasSourceURL { get; set; } + /// <summary> + /// Gets or sets True, if this script is ES6 module. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? IsModule { get; set; } + /// <summary> + /// Gets or sets This script length. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? Length { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/ScriptPosition.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/ScriptPosition.cs index 85975e3..d80265c 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/ScriptPosition.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Debugger/ScriptPosition.cs @@ -5,19 +5,18 @@ using System.Collections.Generic; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger { /// <summary> - /// Collection entry. + /// Location in the source code. /// </summary> [SupportedBy("Chrome")] - public class CollectionEntry + public class ScriptPosition { /// <summary> - /// Gets or sets Entry key of a map-like collection, otherwise not provided. + /// Gets or sets LineNumber /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Runtime.RemoteObject Key { get; set; } + public long LineNumber { get; set; } /// <summary> - /// Gets or sets Entry value. + /// Gets or sets ColumnNumber /// </summary> - public Runtime.RemoteObject Value { get; set; } + public long ColumnNumber { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/SetScriptSourceCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/SetScriptSourceCommand.cs index b1b9a3d..98677b6 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/SetScriptSourceCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Debugger/SetScriptSourceCommand.cs @@ -20,9 +20,9 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger /// </summary> public string ScriptSource { get; set; } /// <summary> - /// Gets or sets If true the change will not actually be applied. Preview mode may be used to get result description without actually modifying the code. + /// Gets or sets If true the change will not actually be applied. Dry run may be used to get result description without actually modifying the code. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? Preview { get; set; } + public bool? DryRun { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/SetScriptSourceCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/SetScriptSourceCommandResponse.cs index 6fc0b8c..33a9acd 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/SetScriptSourceCommandResponse.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Debugger/SetScriptSourceCommandResponse.cs @@ -17,14 +17,19 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public CallFrame[] CallFrames { get; set; } /// <summary> - /// Gets or sets VM-specific description of the changes applied. + /// Gets or sets Whether current call stack was modified after applying the changes. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public object Result { get; set; } + public bool? StackChanged { get; set; } /// <summary> /// Gets or sets Async stack trace, if any. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public StackTrace AsyncStackTrace { get; set; } + public Runtime.StackTrace AsyncStackTrace { get; set; } + /// <summary> + /// Gets or sets Exception details if any. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public Runtime.ExceptionDetails ExceptionDetails { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/SetScriptSourceError.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/SetScriptSourceError.cs deleted file mode 100644 index 1c14f6d..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/SetScriptSourceError.cs +++ /dev/null @@ -1,19 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Error data for setScriptSource command. compileError is a case type for uncompilable script source error. - /// </summary> - [SupportedBy("Chrome")] - public class SetScriptSourceError - { - /// <summary> - /// Gets or sets CompileError - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public object CompileError { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/SetVariableValueCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/SetVariableValueCommand.cs index d515cc4..a85bf64 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/SetVariableValueCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Debugger/SetVariableValueCommand.cs @@ -5,7 +5,7 @@ using System.Collections.Generic; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger { /// <summary> - /// Changes value of variable in a callframe or a closure. Either callframe or function must be specified. Object-based scopes are not supported and must be mutated manually. + /// Changes value of variable in a callframe. Object-based scopes are not supported and must be mutated manually. /// </summary> [Command(ProtocolName.Debugger.SetVariableValue)] [SupportedBy("Chrome")] @@ -26,12 +26,6 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger /// <summary> /// Gets or sets Id of callframe that holds variable. /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string CallFrameId { get; set; } - /// <summary> - /// Gets or sets Object id of closure (function) that holds variable. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string FunctionObjectId { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Debugger/SkipStackFramesCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Debugger/SkipStackFramesCommand.cs deleted file mode 100644 index 5988293..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Debugger/SkipStackFramesCommand.cs +++ /dev/null @@ -1,25 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger -{ - /// <summary> - /// Makes backend skip steps in the sources with names matching given pattern. VM will try leave blacklisted scripts by performing 'step in' several times, finally resorting to 'step out' if unsuccessful. - /// </summary> - [Command(ProtocolName.Debugger.SkipStackFrames)] - [SupportedBy("Chrome")] - public class SkipStackFramesCommand - { - /// <summary> - /// Gets or sets Regular expression defining the scripts to ignore while stepping. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string Script { get; set; } - /// <summary> - /// Gets or sets True, if all content scripts should be ignored. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? SkipContentScripts { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Emulation/SetDefaultBackgroundColorOverrideCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Emulation/SetDefaultBackgroundColorOverrideCommand.cs index 9577979..500fe4b 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Emulation/SetDefaultBackgroundColorOverrideCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Emulation/SetDefaultBackgroundColorOverrideCommand.cs @@ -14,6 +14,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Emulation /// <summary> /// Gets or sets RGBA of the default background color. If not specified, any existing override will be cleared. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public DOM.RGBA Color { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Emulation/SetDeviceMetricsOverrideCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Emulation/SetDeviceMetricsOverrideCommand.cs index a7b4319..df73e8e 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Emulation/SetDeviceMetricsOverrideCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Emulation/SetDeviceMetricsOverrideCommand.cs @@ -49,22 +49,27 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Emulation /// <summary> /// Gets or sets Overriding screen width value in pixels (minimum 0, maximum 10000000). Only used for |mobile==true|. /// </summary> - public long ScreenWidth { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? ScreenWidth { get; set; } /// <summary> /// Gets or sets Overriding screen height value in pixels (minimum 0, maximum 10000000). Only used for |mobile==true|. /// </summary> - public long ScreenHeight { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? ScreenHeight { get; set; } /// <summary> /// Gets or sets Overriding view X position on screen in pixels (minimum 0, maximum 10000000). Only used for |mobile==true|. /// </summary> - public long PositionX { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? PositionX { get; set; } /// <summary> /// Gets or sets Overriding view Y position on screen in pixels (minimum 0, maximum 10000000). Only used for |mobile==true|. /// </summary> - public long PositionY { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? PositionY { get; set; } /// <summary> /// Gets or sets Screen orientation override. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public ScreenOrientation ScreenOrientation { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Emulation/SetVirtualTimePolicyCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Emulation/SetVirtualTimePolicyCommand.cs index f36aa02..96562f0 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Emulation/SetVirtualTimePolicyCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Emulation/SetVirtualTimePolicyCommand.cs @@ -18,6 +18,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Emulation /// <summary> /// Gets or sets If set, after this many virtual milliseconds have elapsed virtual time will be paused and a virtualTimeBudgetExpired event is sent. /// </summary> - public long Budget { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? Budget { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Emulation/ViewportChangedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Emulation/ViewportChangedEvent.cs deleted file mode 100644 index 7c87588..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Emulation/ViewportChangedEvent.cs +++ /dev/null @@ -1,17 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Emulation -{ - /// <summary> - /// Fired when a visible page viewport has changed. Only fired when device metrics are overridden. - /// </summary> - [Event(ProtocolName.Emulation.ViewportChanged)] - [SupportedBy("Chrome")] - public class ViewportChangedEvent - { - /// <summary> - /// Gets or sets Viewport description. - /// </summary> - public Viewport Viewport { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Emulation/VirtualTimeBudgetExpiredEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Emulation/VirtualTimeBudgetExpiredEvent.cs index d13e001..15d2a7c 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Emulation/VirtualTimeBudgetExpiredEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Emulation/VirtualTimeBudgetExpiredEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Emulation { diff --git a/source/ChromeDevTools/Protocol/Chrome/FileSystem/Entry.cs b/source/ChromeDevTools/Protocol/Chrome/FileSystem/Entry.cs deleted file mode 100644 index 8988af2..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/FileSystem/Entry.cs +++ /dev/null @@ -1,41 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.FileSystem -{ - /// <summary> - /// Represents a browser side file or directory. - /// </summary> - [SupportedBy("Chrome")] - public class Entry - { - /// <summary> - /// Gets or sets filesystem: URL for the entry. - /// </summary> - public string Url { get; set; } - /// <summary> - /// Gets or sets The name of the file or directory. - /// </summary> - public string Name { get; set; } - /// <summary> - /// Gets or sets True if the entry is a directory. - /// </summary> - public bool IsDirectory { get; set; } - /// <summary> - /// Gets or sets MIME type of the entry, available for a file only. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string MimeType { get; set; } - /// <summary> - /// Gets or sets ResourceType of the entry, available for a file only. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Page.ResourceType ResourceType { get; set; } - /// <summary> - /// Gets or sets True if the entry is a text file. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? IsTextFile { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestDirectoryContentCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestDirectoryContentCommandResponse.cs deleted file mode 100644 index 0e0424b..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestDirectoryContentCommandResponse.cs +++ /dev/null @@ -1,24 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.FileSystem -{ - /// <summary> - /// Returns content of the directory. - /// </summary> - [CommandResponse(ProtocolName.FileSystem.RequestDirectoryContent)] - [SupportedBy("Chrome")] - public class RequestDirectoryContentCommandResponse - { - /// <summary> - /// Gets or sets 0, if no error. Otherwise, errorCode is set to FileError::ErrorCode value. - /// </summary> - public long ErrorCode { get; set; } - /// <summary> - /// Gets or sets Contains all entries on directory if the command completed successfully. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Entry[] Entries { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestFileContentCommand.cs b/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestFileContentCommand.cs deleted file mode 100644 index 6cbbb2d..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestFileContentCommand.cs +++ /dev/null @@ -1,38 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.FileSystem -{ - /// <summary> - /// Returns content of the file. Result should be sliced into [start, end). - /// </summary> - [Command(ProtocolName.FileSystem.RequestFileContent)] - [SupportedBy("Chrome")] - public class RequestFileContentCommand - { - /// <summary> - /// Gets or sets URL of the file that the frontend is requesting to read from. - /// </summary> - public string Url { get; set; } - /// <summary> - /// Gets or sets True if the content should be read as text, otherwise the result will be returned as base64 encoded text. - /// </summary> - public bool ReadAsText { get; set; } - /// <summary> - /// Gets or sets Specifies the start of range to read. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public long? Start { get; set; } - /// <summary> - /// Gets or sets Specifies the end of range to read exclusively. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public long? End { get; set; } - /// <summary> - /// Gets or sets Overrides charset of the content when content is served as text. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string Charset { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestFileContentCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestFileContentCommandResponse.cs deleted file mode 100644 index 0176897..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestFileContentCommandResponse.cs +++ /dev/null @@ -1,29 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.FileSystem -{ - /// <summary> - /// Returns content of the file. Result should be sliced into [start, end). - /// </summary> - [CommandResponse(ProtocolName.FileSystem.RequestFileContent)] - [SupportedBy("Chrome")] - public class RequestFileContentCommandResponse - { - /// <summary> - /// Gets or sets 0, if no error. Otherwise, errorCode is set to FileError::ErrorCode value. - /// </summary> - public long ErrorCode { get; set; } - /// <summary> - /// Gets or sets Content of the file. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string Content { get; set; } - /// <summary> - /// Gets or sets Charset of the content if it is served as text. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string Charset { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestFileSystemRootCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestFileSystemRootCommandResponse.cs deleted file mode 100644 index 9b97eb9..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestFileSystemRootCommandResponse.cs +++ /dev/null @@ -1,24 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.FileSystem -{ - /// <summary> - /// Returns root directory of the FileSystem, if exists. - /// </summary> - [CommandResponse(ProtocolName.FileSystem.RequestFileSystemRoot)] - [SupportedBy("Chrome")] - public class RequestFileSystemRootCommandResponse - { - /// <summary> - /// Gets or sets 0, if no error. Otherwise, errorCode is set to FileError::ErrorCode value. - /// </summary> - public long ErrorCode { get; set; } - /// <summary> - /// Gets or sets Contains root of the requested FileSystem if the command completed successfully. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Entry Root { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestMetadataCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestMetadataCommandResponse.cs deleted file mode 100644 index 2e52e73..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/FileSystem/RequestMetadataCommandResponse.cs +++ /dev/null @@ -1,24 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.FileSystem -{ - /// <summary> - /// Returns metadata of the entry. - /// </summary> - [CommandResponse(ProtocolName.FileSystem.RequestMetadata)] - [SupportedBy("Chrome")] - public class RequestMetadataCommandResponse - { - /// <summary> - /// Gets or sets 0, if no error. Otherwise, errorCode is set to FileError::ErrorCode value. - /// </summary> - public long ErrorCode { get; set; } - /// <summary> - /// Gets or sets Contains metadata of the entry if the command completed successfully. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Metadata Metadata { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/HeapProfiler/StartSamplingCommand.cs b/source/ChromeDevTools/Protocol/Chrome/HeapProfiler/StartSamplingCommand.cs index ae1eff4..0f7a69d 100644 --- a/source/ChromeDevTools/Protocol/Chrome/HeapProfiler/StartSamplingCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/HeapProfiler/StartSamplingCommand.cs @@ -11,6 +11,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.HeapProfiler /// <summary> /// Gets or sets Average sample interval in bytes. Poisson distribution is used for the intervals. The default value is 32768 bytes. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public double SamplingInterval { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/IO/ReadCommand.cs b/source/ChromeDevTools/Protocol/Chrome/IO/ReadCommand.cs index 77a8993..3e0a5eb 100644 --- a/source/ChromeDevTools/Protocol/Chrome/IO/ReadCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/IO/ReadCommand.cs @@ -18,10 +18,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.IO /// <summary> /// Gets or sets Seek to the specified offset before reading (if not specificed, proceed with offset following the last read). /// </summary> - public long Offset { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? Offset { get; set; } /// <summary> /// Gets or sets Maximum number of bytes to read (left upon the agent discretion if not specified). /// </summary> - public long Size { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? Size { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Input/DispatchKeyEventCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Input/DispatchKeyEventCommand.cs index 6ffe731..04ffa56 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Input/DispatchKeyEventCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Input/DispatchKeyEventCommand.cs @@ -48,6 +48,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Input /// <summary> /// Gets or sets Unique DOM defined string value describing the meaning of the key in the context of active modifiers, keyboard layout, etc (e.g., 'AltGr') (default: ""). /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Key { get; set; } /// <summary> /// Gets or sets Windows virtual key code (default: 0). diff --git a/source/ChromeDevTools/Protocol/Chrome/Input/SynthesizeScrollGestureCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Input/SynthesizeScrollGestureCommand.cs index 45c565f..b28f8b4 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Input/SynthesizeScrollGestureCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Input/SynthesizeScrollGestureCommand.cs @@ -57,14 +57,17 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Input /// <summary> /// Gets or sets The number of times to repeat the gesture (default: 0). /// </summary> - public long RepeatCount { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? RepeatCount { get; set; } /// <summary> /// Gets or sets The number of milliseconds delay between each repeat. (default: 250). /// </summary> - public long RepeatDelayMs { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? RepeatDelayMs { get; set; } /// <summary> /// Gets or sets The name of the interaction markers to generate, if not empty (default: ""). /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string InteractionMarkerName { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Inspector/EvaluateForTestInFrontendEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Inspector/EvaluateForTestInFrontendEvent.cs deleted file mode 100644 index 6f39116..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Inspector/EvaluateForTestInFrontendEvent.cs +++ /dev/null @@ -1,18 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Inspector -{ - [Event(ProtocolName.Inspector.EvaluateForTestInFrontend)] - [SupportedBy("Chrome")] - public class EvaluateForTestInFrontendEvent - { - /// <summary> - /// Gets or sets TestCallId - /// </summary> - public long TestCallId { get; set; } - /// <summary> - /// Gets or sets Script - /// </summary> - public string Script { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Inspector/InspectEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Inspector/InspectEvent.cs deleted file mode 100644 index 59f1a31..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Inspector/InspectEvent.cs +++ /dev/null @@ -1,18 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Inspector -{ - [Event(ProtocolName.Inspector.Inspect)] - [SupportedBy("Chrome")] - public class InspectEvent - { - /// <summary> - /// Gets or sets Object - /// </summary> - public Runtime.RemoteObject Object { get; set; } - /// <summary> - /// Gets or sets Hints - /// </summary> - public object Hints { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Log/EntryAddedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Log/EntryAddedEvent.cs index 7a7eb6c..28c26b5 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Log/EntryAddedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Log/EntryAddedEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Log { diff --git a/source/ChromeDevTools/Protocol/Chrome/Log/LogEntry.cs b/source/ChromeDevTools/Protocol/Chrome/Log/LogEntry.cs index d13f095..909d728 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Log/LogEntry.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Log/LogEntry.cs @@ -29,22 +29,27 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Log /// <summary> /// Gets or sets URL of the resource if known. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Url { get; set; } /// <summary> /// Gets or sets Line number in the resource. /// </summary> - public long LineNumber { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? LineNumber { get; set; } /// <summary> /// Gets or sets JavaScript stack trace. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public Runtime.StackTrace StackTrace { get; set; } /// <summary> /// Gets or sets Identifier of the network request associated with this entry. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string NetworkRequestId { get; set; } /// <summary> /// Gets or sets Identifier of the worker associated with this entry. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string WorkerId { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Network/Cookie.cs b/source/ChromeDevTools/Protocol/Chrome/Network/Cookie.cs index 349c560..53c9341 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Network/Cookie.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Network/Cookie.cs @@ -49,6 +49,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Network /// <summary> /// Gets or sets Cookie SameSite type. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public CookieSameSite SameSite { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Network/EmulateNetworkConditionsCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Network/EmulateNetworkConditionsCommand.cs index 00f3cc2..5787cbc 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Network/EmulateNetworkConditionsCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Network/EmulateNetworkConditionsCommand.cs @@ -30,6 +30,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Network /// <summary> /// Gets or sets Connection type if known. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string ConnectionType { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Network/EnableCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Network/EnableCommand.cs index 9ed2bcc..93921fb 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Network/EnableCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Network/EnableCommand.cs @@ -14,10 +14,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Network /// <summary> /// Gets or sets Buffer size in bytes to use when preserving network payloads (XHRs, etc). /// </summary> - public long MaxTotalBufferSize { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? MaxTotalBufferSize { get; set; } /// <summary> /// Gets or sets Per-resource buffer size in bytes to use when preserving network payloads (XHRs, etc). /// </summary> - public long MaxResourceBufferSize { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? MaxResourceBufferSize { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Network/GetCookiesCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Network/GetCookiesCommand.cs index 3e3b405..736c9b8 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Network/GetCookiesCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Network/GetCookiesCommand.cs @@ -14,6 +14,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Network /// <summary> /// Gets or sets The list of URLs for which applicable cookies will be fetched /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string[] Urls { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Network/Initiator.cs b/source/ChromeDevTools/Protocol/Chrome/Network/Initiator.cs index 65cd26e..d2212b8 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Network/Initiator.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Network/Initiator.cs @@ -18,21 +18,16 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Network /// Gets or sets Initiator JavaScript stack trace, set for Script only. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Console.CallFrame[] StackTrace { get; set; } + public Runtime.StackTrace Stack { get; set; } /// <summary> /// Gets or sets Initiator URL, set for Parser type only. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Url { get; set; } /// <summary> - /// Gets or sets Initiator line number, set for Parser type only. + /// Gets or sets Initiator line number, set for Parser type only (0-based). /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public double LineNumber { get; set; } - /// <summary> - /// Gets or sets Initiator asynchronous JavaScript stack trace, if available. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Console.AsyncStackTrace AsyncStackTrace { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Network/LoadingFailedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Network/LoadingFailedEvent.cs index ed295f3..6e3df63 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Network/LoadingFailedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Network/LoadingFailedEvent.cs @@ -30,5 +30,10 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Network /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public bool? Canceled { get; set; } + /// <summary> + /// Gets or sets The reason why loading was blocked, if any. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public BlockedReason BlockedReason { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Network/Request.cs b/source/ChromeDevTools/Protocol/Chrome/Network/Request.cs index bf96f5c..d34fa12 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Network/Request.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Network/Request.cs @@ -30,6 +30,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Network /// <summary> /// Gets or sets The mixed content status of the request, as defined in http://www.w3.org/TR/mixed-content/ /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string MixedContentType { get; set; } /// <summary> /// Gets or sets Priority of the resource request at the time request is sent. diff --git a/source/ChromeDevTools/Protocol/Chrome/Network/ResourceChangedPriorityEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Network/ResourceChangedPriorityEvent.cs index 35cdf18..551ced6 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Network/ResourceChangedPriorityEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Network/ResourceChangedPriorityEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Network { diff --git a/source/ChromeDevTools/Protocol/Chrome/Network/Response.cs b/source/ChromeDevTools/Protocol/Chrome/Network/Response.cs index b1d058b..634d56b 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Network/Response.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Network/Response.cs @@ -94,6 +94,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Network /// <summary> /// Gets or sets Security details for the request. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public SecurityDetails SecurityDetails { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Network/SecurityDetails.cs b/source/ChromeDevTools/Protocol/Chrome/Network/SecurityDetails.cs index f0dfe03..e82b470 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Network/SecurityDetails.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Network/SecurityDetails.cs @@ -21,6 +21,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Network /// <summary> /// Gets or sets (EC)DH group used by the connection, if applicable. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string KeyExchangeGroup { get; set; } /// <summary> /// Gets or sets Cipher name. @@ -29,6 +30,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Network /// <summary> /// Gets or sets TLS MAC. Note that AEAD ciphers do not have separate MACs. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Mac { get; set; } /// <summary> /// Gets or sets Certificate ID value. diff --git a/source/ChromeDevTools/Protocol/Chrome/Network/SetCookieCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Network/SetCookieCommand.cs index 520b1d9..ebd87bb 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Network/SetCookieCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Network/SetCookieCommand.cs @@ -26,26 +26,32 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Network /// <summary> /// Gets or sets If omitted, the cookie becomes a host-only cookie. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Domain { get; set; } /// <summary> /// Gets or sets Defaults to the path portion of the url parameter. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Path { get; set; } /// <summary> /// Gets or sets Defaults ot false. /// </summary> - public bool Secure { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? Secure { get; set; } /// <summary> /// Gets or sets Defaults to false. /// </summary> - public bool HttpOnly { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? HttpOnly { get; set; } /// <summary> /// Gets or sets Defaults to browser default behavior. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string SameSite { get; set; } /// <summary> /// Gets or sets If omitted, the cookie becomes a session cookie. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public double ExpirationDate { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Network/WebSocketCreatedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Network/WebSocketCreatedEvent.cs index ea7a802..be812cc 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Network/WebSocketCreatedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Network/WebSocketCreatedEvent.cs @@ -20,6 +20,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Network /// <summary> /// Gets or sets Request initiator. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public Initiator Initiator { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Page/CaptureScreenshotCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Page/CaptureScreenshotCommand.cs index 01035dd..d3599a8 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Page/CaptureScreenshotCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Page/CaptureScreenshotCommand.cs @@ -14,10 +14,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Page /// <summary> /// Gets or sets Image compression format (defaults to png). /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Format { get; set; } /// <summary> /// Gets or sets Compression quality from range [0..100] (jpeg only). /// </summary> - public long Quality { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? Quality { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Page/ConfigureOverlayCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Page/ConfigureOverlayCommand.cs index fe5c673..ddb6c17 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Page/ConfigureOverlayCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Page/ConfigureOverlayCommand.cs @@ -14,10 +14,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Page /// <summary> /// Gets or sets Whether overlay should be suspended and not consume any resources. /// </summary> - public bool Suspended { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? Suspended { get; set; } /// <summary> /// Gets or sets Overlay message to display. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Message { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Page/FrameResource.cs b/source/ChromeDevTools/Protocol/Chrome/Page/FrameResource.cs index 827b077..b166f37 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Page/FrameResource.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Page/FrameResource.cs @@ -25,18 +25,22 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Page /// <summary> /// Gets or sets last-modified timestamp as reported by server. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public double LastModified { get; set; } /// <summary> /// Gets or sets Resource content size. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public double ContentSize { get; set; } /// <summary> /// Gets or sets True if the resource failed to load. /// </summary> - public bool Failed { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? Failed { get; set; } /// <summary> /// Gets or sets True if the resource was canceled during loading. /// </summary> - public bool Canceled { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? Canceled { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Page/FrameResourceTree.cs b/source/ChromeDevTools/Protocol/Chrome/Page/FrameResourceTree.cs index 6cace98..f58ae77 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Page/FrameResourceTree.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Page/FrameResourceTree.cs @@ -19,35 +19,9 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Page /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public FrameResourceTree[] ChildFrames { get; set; } - public class ResourcesArray - { - /// <summary> - /// Gets or sets Resource URL. - /// </summary> - public string Url { get; set; } - /// <summary> - /// Gets or sets Type of this resource. - /// </summary> - public ResourceType Type { get; set; } - /// <summary> - /// Gets or sets Resource mimeType as determined by the browser. - /// </summary> - public string MimeType { get; set; } - /// <summary> - /// Gets or sets True if the resource failed to load. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? Failed { get; set; } - /// <summary> - /// Gets or sets True if the resource was canceled during loading. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? Canceled { get; set; } - } - /// <summary> /// Gets or sets Information about frame resources. /// </summary> - public ResourcesArray[] Resources { get; set; } + public FrameResource[] Resources { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Page/GetAppManifestCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/Page/GetAppManifestCommandResponse.cs index d9e38cf..8371023 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Page/GetAppManifestCommandResponse.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Page/GetAppManifestCommandResponse.cs @@ -19,6 +19,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Page /// <summary> /// Gets or sets Manifest content. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Data { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Page/NavigateCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Page/NavigateCommand.cs index 388f6d4..a48af94 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Page/NavigateCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Page/NavigateCommand.cs @@ -18,6 +18,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Page /// <summary> /// Gets or sets Referrer URL. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Referrer { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Page/NavigationRequestedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Page/NavigationRequestedEvent.cs index 6dfccb8..177a223 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Page/NavigationRequestedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Page/NavigationRequestedEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Page { diff --git a/source/ChromeDevTools/Protocol/Chrome/Page/PrintToPDFCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/Page/PrintToPDFCommandResponse.cs index b9aebc8..7532952 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Page/PrintToPDFCommandResponse.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Page/PrintToPDFCommandResponse.cs @@ -5,16 +5,15 @@ using System.Collections.Generic; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Page { /// <summary> - /// Sets overlay message. + /// Print page as pdf. /// </summary> - [Command(ProtocolName.Page.SetOverlayMessage)] + [CommandResponse(ProtocolName.Page.PrintToPDF)] [SupportedBy("Chrome")] - public class SetOverlayMessageCommand + public class PrintToPDFCommandResponse { /// <summary> - /// Gets or sets Overlay message to display when paused in debugger. + /// Gets or sets Base64-encoded pdf data. /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string Message { get; set; } + public string Data { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Page/ScreencastFrameEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Page/ScreencastFrameEvent.cs index a9dfb3c..c8f2bff 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Page/ScreencastFrameEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Page/ScreencastFrameEvent.cs @@ -20,7 +20,6 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Page /// <summary> /// Gets or sets Frame number. /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public long? FrameNumber { get; set; } + public long SessionId { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Page/SetDeviceMetricsOverrideCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Page/SetDeviceMetricsOverrideCommand.cs index 1cae559..9405276 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Page/SetDeviceMetricsOverrideCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Page/SetDeviceMetricsOverrideCommand.cs @@ -49,22 +49,27 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Page /// <summary> /// Gets or sets Overriding screen width value in pixels (minimum 0, maximum 10000000). Only used for |mobile==true|. /// </summary> - public long ScreenWidth { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? ScreenWidth { get; set; } /// <summary> /// Gets or sets Overriding screen height value in pixels (minimum 0, maximum 10000000). Only used for |mobile==true|. /// </summary> - public long ScreenHeight { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? ScreenHeight { get; set; } /// <summary> /// Gets or sets Overriding view X position on screen in pixels (minimum 0, maximum 10000000). Only used for |mobile==true|. /// </summary> - public long PositionX { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? PositionX { get; set; } /// <summary> /// Gets or sets Overriding view Y position on screen in pixels (minimum 0, maximum 10000000). Only used for |mobile==true|. /// </summary> - public long PositionY { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? PositionY { get; set; } /// <summary> /// Gets or sets Screen orientation override. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public Emulation.ScreenOrientation ScreenOrientation { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Page/StartScreencastCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Page/StartScreencastCommand.cs index 1a3e617..67ee4c2 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Page/StartScreencastCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Page/StartScreencastCommand.cs @@ -31,5 +31,10 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Page /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public long? MaxHeight { get; set; } + /// <summary> + /// Gets or sets Send every n-th frame. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? EveryNthFrame { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Power/DataAvailableEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Power/DataAvailableEvent.cs deleted file mode 100644 index 37fe165..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Power/DataAvailableEvent.cs +++ /dev/null @@ -1,14 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Power -{ - [Event(ProtocolName.Power.DataAvailable)] - [SupportedBy("Chrome")] - public class DataAvailableEvent - { - /// <summary> - /// Gets or sets List of power events. - /// </summary> - public PowerEvent[] Value { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Profiler/Profile.cs b/source/ChromeDevTools/Protocol/Chrome/Profiler/Profile.cs index b44657d..76a480f 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Profiler/Profile.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Profiler/Profile.cs @@ -8,18 +8,18 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Profiler /// Profile. /// </summary> [SupportedBy("Chrome")] - public class CPUProfile + public class Profile { /// <summary> - /// Gets or sets Head + /// Gets or sets The list of profile nodes. First item is the root node. /// </summary> - public CPUProfileNode Head { get; set; } + public ProfileNode[] Nodes { get; set; } /// <summary> - /// Gets or sets Profiling start time in seconds. + /// Gets or sets Profiling start timestamp in microseconds. /// </summary> public double StartTime { get; set; } /// <summary> - /// Gets or sets Profiling end time in seconds. + /// Gets or sets Profiling end timestamp in microseconds. /// </summary> public double EndTime { get; set; } /// <summary> @@ -28,9 +28,9 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Profiler [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public long[] Samples { get; set; } /// <summary> - /// Gets or sets Timestamps of the samples in microseconds. + /// Gets or sets Time intervals between adjacent samples in microseconds. The first delta is relative to the profile startTime. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public double[] Timestamps { get; set; } + public long[] TimeDeltas { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Profiler/ProfileNode.cs b/source/ChromeDevTools/Protocol/Chrome/Profiler/ProfileNode.cs index 3beec74..d85fa41 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Profiler/ProfileNode.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Profiler/ProfileNode.cs @@ -21,18 +21,22 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Profiler /// <summary> /// Gets or sets Number of samples where this node was on top of the call stack. /// </summary> - public long HitCount { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? HitCount { get; set; } /// <summary> /// Gets or sets Child node ids. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public long[] Children { get; set; } /// <summary> /// Gets or sets The reason of being not optimized. The function may be deoptimized or marked as don't optimize. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string DeoptReason { get; set; } /// <summary> /// Gets or sets An array of source position ticks. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public PositionTickInfo[] PositionTicks { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Rendering/SetShowViewportSizeOnResizeCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Rendering/SetShowViewportSizeOnResizeCommand.cs index e3a869e..1442c25 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Rendering/SetShowViewportSizeOnResizeCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Rendering/SetShowViewportSizeOnResizeCommand.cs @@ -2,12 +2,12 @@ using MasterDevs.ChromeDevTools; using Newtonsoft.Json; using System.Collections.Generic; -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Page +namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Rendering { /// <summary> /// Paints viewport size upon main frame resize. /// </summary> - [Command(ProtocolName.Page.SetShowViewportSizeOnResize)] + [Command(ProtocolName.Rendering.SetShowViewportSizeOnResize)] [SupportedBy("Chrome")] public class SetShowViewportSizeOnResizeCommand { @@ -15,10 +15,5 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Page /// Gets or sets Whether to paint size or not. /// </summary> public bool Show { get; set; } - /// <summary> - /// Gets or sets Whether to paint grid as well. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? ShowGrid { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/AwaitPromiseCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/AwaitPromiseCommand.cs index 7d6629d..3b8dae0 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/AwaitPromiseCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/AwaitPromiseCommand.cs @@ -18,10 +18,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime /// <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; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/AwaitPromiseCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/AwaitPromiseCommandResponse.cs index dfa7891..a9978d5 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/AwaitPromiseCommandResponse.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/AwaitPromiseCommandResponse.cs @@ -18,6 +18,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime /// <summary> /// Gets or sets Exception details if stack strace is available. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public ExceptionDetails ExceptionDetails { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/CallArgument.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/CallArgument.cs index 515af42..a015ba9 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/CallArgument.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/CallArgument.cs @@ -5,25 +5,25 @@ using System.Collections.Generic; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime { /// <summary> - /// Represents function call argument. Either remote object id <code>objectId</code> or primitive <code>value</code> or neither of (for undefined) them should be specified. + /// Represents function call argument. Either remote object id <code>objectId</code>, primitive <code>value</code>, unserializable primitive value or neither of (for undefined) them should be specified. /// </summary> [SupportedBy("Chrome")] public class CallArgument { /// <summary> - /// Gets or sets Primitive value, or description string if the value can not be JSON-stringified (like NaN, Infinity, -Infinity, -0). + /// Gets or sets Primitive value. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public object Value { get; set; } /// <summary> - /// Gets or sets Remote object handle. + /// Gets or sets Primitive value which can not be JSON-stringified. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string ObjectId { get; set; } + public UnserializableValue UnserializableValue { get; set; } /// <summary> - /// Gets or sets Object type. + /// Gets or sets Remote object handle. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string Type { get; set; } + public string ObjectId { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/CallFunctionOnCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/CallFunctionOnCommand.cs index a8ce50b..3be066a 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/CallFunctionOnCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/CallFunctionOnCommand.cs @@ -25,10 +25,10 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public CallArgument[] Arguments { get; set; } /// <summary> - /// Gets or sets Specifies whether function call should stop on exceptions and mute console. Overrides setPauseOnException state. + /// Gets or sets In silent mode exceptions thrown during evaluation are not reported and do not pause execution. Overrides <code>setPauseOnException</code> state. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? DoNotPauseOnExceptionsAndMuteConsole { get; set; } + public bool? Silent { get; set; } /// <summary> /// Gets or sets Whether the result is expected to be a JSON object which should be sent by value. /// </summary> @@ -39,5 +39,15 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public bool? GeneratePreview { get; set; } + /// <summary> + /// Gets or sets Whether execution should be treated as initiated by user in the UI. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? UserGesture { get; set; } + /// <summary> + /// Gets or sets Whether execution should wait for promise to be resolved. If the result of evaluation is not a Promise, it's considered to be an error. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? AwaitPromise { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/CallFunctionOnCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/CallFunctionOnCommandResponse.cs index a411171..7bed517 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/CallFunctionOnCommandResponse.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/CallFunctionOnCommandResponse.cs @@ -16,9 +16,9 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime /// </summary> public RemoteObject Result { get; set; } /// <summary> - /// Gets or sets True if the result was thrown during the evaluation. + /// Gets or sets Exception details. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? WasThrown { get; set; } + public ExceptionDetails ExceptionDetails { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/ConsoleAPICalledEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/ConsoleAPICalledEvent.cs index 12c6810..f1d70d3 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/ConsoleAPICalledEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/ConsoleAPICalledEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime { @@ -28,6 +28,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime /// <summary> /// Gets or sets Stack trace captured when the call was made. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public StackTrace StackTrace { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/EvaluateCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/EvaluateCommand.cs index 9026149..53402a0 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/EvaluateCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/EvaluateCommand.cs @@ -26,12 +26,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime [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. + /// Gets or sets In silent mode exceptions thrown during evaluation are not reported and do not pause execution. Overrides <code>setPauseOnException</code> state. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? DoNotPauseOnExceptionsAndMuteConsole { get; set; } + public bool? Silent { get; set; } /// <summary> - /// Gets or sets Specifies in which isolated context to perform evaluation. 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. + /// Gets or sets Specifies in which execution context to perform evaluation. If the parameter is omitted the evaluation will be performed in the context of the inspected page. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public long? ContextId { get; set; } @@ -45,5 +45,15 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public bool? GeneratePreview { get; set; } + /// <summary> + /// Gets or sets Whether execution should be treated as initiated by user in the UI. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? UserGesture { get; set; } + /// <summary> + /// Gets or sets Whether execution should wait for promise to be resolved. If the result of evaluation is not a Promise, it's considered to be an error. + /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? AwaitPromise { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/EvaluateCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/EvaluateCommandResponse.cs index 702bda7..1f7d767 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/EvaluateCommandResponse.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/EvaluateCommandResponse.cs @@ -16,14 +16,9 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime /// </summary> public RemoteObject Result { get; set; } /// <summary> - /// Gets or sets True if the result was thrown during the evaluation. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? WasThrown { get; set; } - /// <summary> /// Gets or sets Exception details. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Debugger.ExceptionDetails ExceptionDetails { get; set; } + public ExceptionDetails ExceptionDetails { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/EventListener.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/EventListener.cs deleted file mode 100644 index 59c441a..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/EventListener.cs +++ /dev/null @@ -1,31 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime -{ - /// <summary> - /// Object event listener. - /// </summary> - [SupportedBy("Chrome")] - public class EventListener - { - /// <summary> - /// Gets or sets <code>EventListener</code>'s type. - /// </summary> - public string Type { get; set; } - /// <summary> - /// Gets or sets <code>EventListener</code>'s useCapture. - /// </summary> - public bool UseCapture { get; set; } - /// <summary> - /// Gets or sets Handler code location. - /// </summary> - public Debugger.Location Location { get; set; } - /// <summary> - /// Gets or sets Event handler function value. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Runtime.RemoteObject Handler { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/ExceptionDetails.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/ExceptionDetails.cs index 0d2b0ba..ef3b64d 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/ExceptionDetails.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/ExceptionDetails.cs @@ -29,22 +29,27 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime /// <summary> /// Gets or sets Script ID of the exception location. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string ScriptId { get; set; } /// <summary> /// Gets or sets URL of the exception location, to be used when the script was not reported. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Url { get; set; } /// <summary> /// Gets or sets JavaScript stack trace if available. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public StackTrace StackTrace { get; set; } /// <summary> /// Gets or sets Exception object if available. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public RemoteObject Exception { get; set; } /// <summary> /// Gets or sets Identifier of the context where exception happened. /// </summary> - public long ExecutionContextId { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? ExecutionContextId { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/ExceptionRevokedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/ExceptionRevokedEvent.cs index 7869156..202cfcb 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/ExceptionRevokedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/ExceptionRevokedEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime { diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/ExceptionThrownEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/ExceptionThrownEvent.cs index 380c89b..a695600 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/ExceptionThrownEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/ExceptionThrownEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime { diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/ExecutionContextDescription.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/ExecutionContextDescription.cs index 38c8116..bc0d48a 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/ExecutionContextDescription.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/ExecutionContextDescription.cs @@ -15,11 +15,6 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime /// </summary> public long Id { get; set; } /// <summary> - /// Gets or sets True if this is a context where inpspected web page scripts run. False if it is a content script isolated context. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? IsPageContext { get; set; } - /// <summary> /// Gets or sets Execution context origin. /// </summary> public string Origin { get; set; } @@ -28,8 +23,9 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime /// </summary> public string Name { get; set; } /// <summary> - /// Gets or sets Id of the owning frame. May be an empty string if the context is not associated with a frame. + /// Gets or sets Embedder-specific auxiliary data. /// </summary> - public string FrameId { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public object AuxData { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/GetEventListenersCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/GetEventListenersCommand.cs deleted file mode 100644 index ca02539..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/GetEventListenersCommand.cs +++ /dev/null @@ -1,24 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime -{ - /// <summary> - /// Returns event listeners of the given object. - /// </summary> - [Command(ProtocolName.Runtime.GetEventListeners)] - [SupportedBy("Chrome")] - public class GetEventListenersCommand - { - /// <summary> - /// Gets or sets Identifier of the object to return listeners for. - /// </summary> - public string ObjectId { get; set; } - /// <summary> - /// Gets or sets Symbolic group name for handler value. Handler value is not returned without this parameter specified. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string ObjectGroup { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/GetPropertiesCommandResponse.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/GetPropertiesCommandResponse.cs index 4ab5014..db45ce6 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/GetPropertiesCommandResponse.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/GetPropertiesCommandResponse.cs @@ -23,6 +23,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime /// <summary> /// Gets or sets Exception details. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public ExceptionDetails ExceptionDetails { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/InspectRequestedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/InspectRequestedEvent.cs index f4c6371..4234047 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/InspectRequestedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/InspectRequestedEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime { diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/RemoteObject.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/RemoteObject.cs index a900634..401fe9c 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/RemoteObject.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/RemoteObject.cs @@ -32,6 +32,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime /// <summary> /// Gets or sets Primitive value which can not be JSON-stringified does not have <code>value</code>, but gets this property. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public UnserializableValue UnserializableValue { get; set; } /// <summary> /// Gets or sets String representation of the object. diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/RunScriptCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/RunScriptCommand.cs index 0df7fb4..3534bd0 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/RunScriptCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/RunScriptCommand.cs @@ -18,30 +18,37 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime /// <summary> /// Gets or sets Specifies in which execution context to perform script run. If the parameter is omitted 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; } /// <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; } /// <summary> /// Gets or sets In silent mode exceptions thrown during evaluation are not reported and do not pause execution. Overrides <code>setPauseOnException</code> state. /// </summary> - public bool Silent { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? Silent { get; set; } /// <summary> /// Gets or sets Determines whether Command Line API should be available during the evaluation. /// </summary> - public bool IncludeCommandLineAPI { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? IncludeCommandLineAPI { get; set; } /// <summary> /// Gets or sets Whether the result is expected to be a JSON object which 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; } /// <summary> /// Gets or sets Whether execution should wait for promise to be resolved. If the result of evaluation is not a Promise, it's considered to be an error. /// </summary> - public bool AwaitPromise { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? AwaitPromise { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Runtime/StackTrace.cs b/source/ChromeDevTools/Protocol/Chrome/Runtime/StackTrace.cs index d509aea..0217d89 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Runtime/StackTrace.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Runtime/StackTrace.cs @@ -2,27 +2,32 @@ using MasterDevs.ChromeDevTools; using Newtonsoft.Json; using System.Collections.Generic; -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger +namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime { /// <summary> - /// JavaScript call stack, including async stack traces. + /// Call frames for assertions or error messages. /// </summary> [SupportedBy("Chrome")] public class StackTrace { /// <summary> - /// Gets or sets Call frames of the stack trace. + /// 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 JavaScript function name. /// </summary> public CallFrame[] CallFrames { get; set; } /// <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. + /// Gets or sets Asynchronous JavaScript stack trace that preceded this stack, if available. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string Description { get; set; } + public StackTrace Parent { get; set; } /// <summary> - /// Gets or sets Async stack trace, if any. + /// Gets or sets Creation frame of the Promise which produced the next synchronous trace when resolved, if available. /// </summary> [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public StackTrace AsyncStackTrace { get; set; } + public CallFrame PromiseCreationFrame { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Security/SecurityStateChangedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Security/SecurityStateChangedEvent.cs index 27bc687..607b782 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Security/SecurityStateChangedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Security/SecurityStateChangedEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Security { @@ -28,6 +28,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Security /// <summary> /// Gets or sets Overrides user-visible description of the state. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Summary { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/DebugOnStartUpdatedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/DebugOnStartUpdatedEvent.cs deleted file mode 100644 index bd15879..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/DebugOnStartUpdatedEvent.cs +++ /dev/null @@ -1,14 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.ServiceWorker -{ - [Event(ProtocolName.ServiceWorker.DebugOnStartUpdated)] - [SupportedBy("Chrome")] - public class DebugOnStartUpdatedEvent - { - /// <summary> - /// Gets or sets DebugOnStart - /// </summary> - public bool DebugOnStart { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/DispatchMessageEvent.cs b/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/DispatchMessageEvent.cs deleted file mode 100644 index 7cf42ac..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/DispatchMessageEvent.cs +++ /dev/null @@ -1,18 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.ServiceWorker -{ - [Event(ProtocolName.ServiceWorker.DispatchMessage)] - [SupportedBy("Chrome")] - public class DispatchMessageEvent - { - /// <summary> - /// Gets or sets WorkerId - /// </summary> - public string WorkerId { get; set; } - /// <summary> - /// Gets or sets Message - /// </summary> - public string Message { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/ServiceWorkerRegistration.cs b/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/ServiceWorkerRegistration.cs index 2d2df74..e024109 100644 --- a/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/ServiceWorkerRegistration.cs +++ b/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/ServiceWorkerRegistration.cs @@ -21,7 +21,6 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.ServiceWorker /// <summary> /// Gets or sets IsDeleted /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? IsDeleted { get; set; } + public bool IsDeleted { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/ServiceWorkerVersion.cs b/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/ServiceWorkerVersion.cs index 60cbbf0..a40f2d5 100644 --- a/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/ServiceWorkerVersion.cs +++ b/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/ServiceWorkerVersion.cs @@ -43,10 +43,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.ServiceWorker /// <summary> /// Gets or sets ControlledClients /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string[] ControlledClients { get; set; } /// <summary> /// Gets or sets TargetId /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string TargetId { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/WorkerCreatedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/WorkerCreatedEvent.cs deleted file mode 100644 index d1395f1..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/WorkerCreatedEvent.cs +++ /dev/null @@ -1,18 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.ServiceWorker -{ - [Event(ProtocolName.ServiceWorker.WorkerCreated)] - [SupportedBy("Chrome")] - public class WorkerCreatedEvent - { - /// <summary> - /// Gets or sets WorkerId - /// </summary> - public string WorkerId { get; set; } - /// <summary> - /// Gets or sets Url - /// </summary> - public string Url { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/WorkerTerminatedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/WorkerTerminatedEvent.cs deleted file mode 100644 index 641e6c8..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/ServiceWorker/WorkerTerminatedEvent.cs +++ /dev/null @@ -1,14 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.ServiceWorker -{ - [Event(ProtocolName.ServiceWorker.WorkerTerminated)] - [SupportedBy("Chrome")] - public class WorkerTerminatedEvent - { - /// <summary> - /// Gets or sets WorkerId - /// </summary> - public string WorkerId { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/SystemInfo/GPUInfo.cs b/source/ChromeDevTools/Protocol/Chrome/SystemInfo/GPUInfo.cs index 2cbf983..cec7f21 100644 --- a/source/ChromeDevTools/Protocol/Chrome/SystemInfo/GPUInfo.cs +++ b/source/ChromeDevTools/Protocol/Chrome/SystemInfo/GPUInfo.cs @@ -17,10 +17,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.SystemInfo /// <summary> /// Gets or sets An optional dictionary of additional GPU related attributes. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public object AuxAttributes { get; set; } /// <summary> /// Gets or sets An optional dictionary of graphics features and their status. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public object FeatureStatus { get; set; } /// <summary> /// Gets or sets An optional array of GPU driver bug workarounds. diff --git a/source/ChromeDevTools/Protocol/Chrome/Target/AttachedToTargetEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Target/AttachedToTargetEvent.cs index 4fbccce..f8f3bd2 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Target/AttachedToTargetEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Target/AttachedToTargetEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Target { diff --git a/source/ChromeDevTools/Protocol/Chrome/Target/CreateTargetCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Target/CreateTargetCommand.cs index a4b5562..3ebfb8b 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Target/CreateTargetCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Target/CreateTargetCommand.cs @@ -18,14 +18,17 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Target /// <summary> /// Gets or sets Frame width in DIP (headless chrome only). /// </summary> - public long Width { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? Width { get; set; } /// <summary> /// Gets or sets Frame height in DIP (headless chrome only). /// </summary> - public long Height { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public long? Height { get; set; } /// <summary> /// Gets or sets The browser context to create the page in (headless chrome only). /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string BrowserContextId { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Target/DetachedFromTargetEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Target/DetachedFromTargetEvent.cs index 2ca0c68..ceca8bd 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Target/DetachedFromTargetEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Target/DetachedFromTargetEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Target { diff --git a/source/ChromeDevTools/Protocol/Chrome/Target/ReceivedMessageFromTargetEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Target/ReceivedMessageFromTargetEvent.cs index b1e50c8..fc71fe5 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Target/ReceivedMessageFromTargetEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Target/ReceivedMessageFromTargetEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Target { diff --git a/source/ChromeDevTools/Protocol/Chrome/Target/TargetCreatedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Target/TargetCreatedEvent.cs index abefba0..29084c4 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Target/TargetCreatedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Target/TargetCreatedEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Target { diff --git a/source/ChromeDevTools/Protocol/Chrome/Target/TargetDestroyedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Target/TargetDestroyedEvent.cs index 897fd66..da09f06 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Target/TargetDestroyedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Target/TargetDestroyedEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Target { diff --git a/source/ChromeDevTools/Protocol/Chrome/Tethering/AcceptedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Tethering/AcceptedEvent.cs index 2239c84..41b9f8a 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Tethering/AcceptedEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Tethering/AcceptedEvent.cs @@ -1,4 +1,4 @@ -using MasterDevs.ChromeDevTools; +using MasterDevs.ChromeDevTools;using Newtonsoft.Json; namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Tethering { diff --git a/source/ChromeDevTools/Protocol/Chrome/Timeline/EventRecordedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Timeline/EventRecordedEvent.cs deleted file mode 100644 index ec6936c..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Timeline/EventRecordedEvent.cs +++ /dev/null @@ -1,17 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Timeline -{ - /// <summary> - /// Deprecated. - /// </summary> - [Event(ProtocolName.Timeline.EventRecorded)] - [SupportedBy("Chrome")] - public class EventRecordedEvent - { - /// <summary> - /// Gets or sets Timeline event record data. - /// </summary> - public TimelineEvent Record { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Timeline/StartCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Timeline/StartCommand.cs deleted file mode 100644 index 888b9a9..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Timeline/StartCommand.cs +++ /dev/null @@ -1,40 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Timeline -{ - /// <summary> - /// Deprecated. - /// </summary> - [Command(ProtocolName.Timeline.Start)] - [SupportedBy("Chrome")] - public class StartCommand - { - /// <summary> - /// Gets or sets Samples JavaScript stack traces up to <code>maxCallStackDepth</code>, defaults to 5. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public long? MaxCallStackDepth { get; set; } - /// <summary> - /// Gets or sets Whether instrumentation events should be buffered and returned upon <code>stop</code> call. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? BufferEvents { get; set; } - /// <summary> - /// Gets or sets Coma separated event types to issue although bufferEvents is set. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string LiveEvents { get; set; } - /// <summary> - /// Gets or sets Whether counters data should be included into timeline events. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? IncludeCounters { get; set; } - /// <summary> - /// Gets or sets Whether events from GPU process should be collected. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public bool? IncludeGPUEvents { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Timeline/TimelineEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Timeline/TimelineEvent.cs deleted file mode 100644 index e1118e1..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Timeline/TimelineEvent.cs +++ /dev/null @@ -1,51 +0,0 @@ -using MasterDevs.ChromeDevTools; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Timeline -{ - /// <summary> - /// Timeline record contains information about the recorded activity. - /// </summary> - [SupportedBy("Chrome")] - public class TimelineEvent - { - /// <summary> - /// Gets or sets Event type. - /// </summary> - public string Type { get; set; } - /// <summary> - /// Gets or sets Event data. - /// </summary> - public object Data { get; set; } - /// <summary> - /// Gets or sets Start time. - /// </summary> - public double StartTime { get; set; } - /// <summary> - /// Gets or sets End time. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public double EndTime { get; set; } - /// <summary> - /// Gets or sets Nested records. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public TimelineEvent[] Children { get; set; } - /// <summary> - /// Gets or sets If present, identifies the thread that produced the event. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string Thread { get; set; } - /// <summary> - /// Gets or sets Stack trace. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public Console.CallFrame[] StackTrace { get; set; } - /// <summary> - /// Gets or sets Unique identifier of the frame within the page that the event relates to. - /// </summary> - [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] - public string FrameId { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Tracing/StartCommand.cs b/source/ChromeDevTools/Protocol/Chrome/Tracing/StartCommand.cs index ce026d2..bb959d8 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Tracing/StartCommand.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Tracing/StartCommand.cs @@ -29,10 +29,12 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Tracing /// <summary> /// Gets or sets Whether to report trace events as series of dataCollected events or to save trace to a stream (defaults to <code>ReportEvents</code>). /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string TransferMode { get; set; } /// <summary> /// Gets or sets /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public TraceConfig TraceConfig { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Tracing/TraceConfig.cs b/source/ChromeDevTools/Protocol/Chrome/Tracing/TraceConfig.cs index 26eaf61..64f74d3 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Tracing/TraceConfig.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Tracing/TraceConfig.cs @@ -13,34 +13,42 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Tracing /// <summary> /// Gets or sets Controls how the trace buffer stores data. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string RecordMode { get; set; } /// <summary> /// Gets or sets Turns on JavaScript stack sampling. /// </summary> - public bool EnableSampling { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? EnableSampling { get; set; } /// <summary> /// Gets or sets Turns on system tracing. /// </summary> - public bool EnableSystrace { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? EnableSystrace { get; set; } /// <summary> /// Gets or sets Turns on argument filter. /// </summary> - public bool EnableArgumentFilter { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public bool? EnableArgumentFilter { get; set; } /// <summary> /// Gets or sets Included category filters. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string[] IncludedCategories { get; set; } /// <summary> /// Gets or sets Excluded category filters. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string[] ExcludedCategories { get; set; } /// <summary> /// Gets or sets Configuration to synthesize the delays in tracing. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string[] SyntheticDelays { get; set; } /// <summary> /// Gets or sets Configuration for memory dump triggers. Used only when "memory-infra" category is enabled. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public MemoryDumpConfig MemoryDumpConfig { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Tracing/TracingCompleteEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Tracing/TracingCompleteEvent.cs index 68d6c48..ddf0a7d 100644 --- a/source/ChromeDevTools/Protocol/Chrome/Tracing/TracingCompleteEvent.cs +++ b/source/ChromeDevTools/Protocol/Chrome/Tracing/TracingCompleteEvent.cs @@ -12,6 +12,7 @@ namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Tracing /// <summary> /// Gets or sets A handle of the stream that holds resulting trace data. /// </summary> + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public string Stream { get; set; } } } diff --git a/source/ChromeDevTools/Protocol/Chrome/Worker/DispatchMessageFromWorkerEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Worker/DispatchMessageFromWorkerEvent.cs deleted file mode 100644 index 441d9ba..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Worker/DispatchMessageFromWorkerEvent.cs +++ /dev/null @@ -1,18 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Worker -{ - [Event(ProtocolName.Worker.DispatchMessageFromWorker)] - [SupportedBy("Chrome")] - public class DispatchMessageFromWorkerEvent - { - /// <summary> - /// Gets or sets WorkerId - /// </summary> - public string WorkerId { get; set; } - /// <summary> - /// Gets or sets Message - /// </summary> - public string Message { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Worker/WorkerCreatedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Worker/WorkerCreatedEvent.cs deleted file mode 100644 index 54811ed..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Worker/WorkerCreatedEvent.cs +++ /dev/null @@ -1,22 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Worker -{ - [Event(ProtocolName.Worker.WorkerCreated)] - [SupportedBy("Chrome")] - public class WorkerCreatedEvent - { - /// <summary> - /// Gets or sets WorkerId - /// </summary> - public string WorkerId { get; set; } - /// <summary> - /// Gets or sets Url - /// </summary> - public string Url { get; set; } - /// <summary> - /// Gets or sets InspectorConnected - /// </summary> - public bool InspectorConnected { get; set; } - } -} diff --git a/source/ChromeDevTools/Protocol/Chrome/Worker/WorkerTerminatedEvent.cs b/source/ChromeDevTools/Protocol/Chrome/Worker/WorkerTerminatedEvent.cs deleted file mode 100644 index 9f94c83..0000000 --- a/source/ChromeDevTools/Protocol/Chrome/Worker/WorkerTerminatedEvent.cs +++ /dev/null @@ -1,14 +0,0 @@ -using MasterDevs.ChromeDevTools;using Newtonsoft.Json; - -namespace MasterDevs.ChromeDevTools.Protocol.Chrome.Worker -{ - [Event(ProtocolName.Worker.WorkerTerminated)] - [SupportedBy("Chrome")] - public class WorkerTerminatedEvent - { - /// <summary> - /// Gets or sets WorkerId - /// </summary> - public string WorkerId { get; set; } - } -} diff --git a/source/MasterDevs.ChromeDevTools.Tests/SerializationTests.cs b/source/MasterDevs.ChromeDevTools.Tests/SerializationTests.cs index 400ca82..05fef10 100644 --- a/source/MasterDevs.ChromeDevTools.Tests/SerializationTests.cs +++ b/source/MasterDevs.ChromeDevTools.Tests/SerializationTests.cs @@ -1,12 +1,7 @@ -using MasterDevs.ChromeDevTools.Protocol.Chrome.Debugger; -using MasterDevs.ChromeDevTools.Protocol.Chrome.DOM; +using MasterDevs.ChromeDevTools.Protocol.Chrome.DOM; using Microsoft.VisualStudio.TestTools.UnitTesting; using Newtonsoft.Json; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; +using MasterDevs.ChromeDevTools.Protocol.Chrome.Runtime; namespace MasterDevs.ChromeDevTools.Tests { -- GitLab