You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

2911 lines
107 KiB

  1. // Copyright 2019 Google LLC.
  2. // Use of this source code is governed by a BSD-style
  3. // license that can be found in the LICENSE file.
  4. // Code generated file. DO NOT EDIT.
  5. // Package clouddebugger provides access to the Stackdriver Debugger API.
  6. //
  7. // For product documentation, see: https://cloud.google.com/debugger
  8. //
  9. // Creating a client
  10. //
  11. // Usage example:
  12. //
  13. // import "google.golang.org/api/clouddebugger/v2"
  14. // ...
  15. // ctx := context.Background()
  16. // clouddebuggerService, err := clouddebugger.NewService(ctx)
  17. //
  18. // In this example, Google Application Default Credentials are used for authentication.
  19. //
  20. // For information on how to create and obtain Application Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.
  21. //
  22. // Other authentication options
  23. //
  24. // By default, all available scopes (see "Constants") are used to authenticate. To restrict scopes, use option.WithScopes:
  25. //
  26. // clouddebuggerService, err := clouddebugger.NewService(ctx, option.WithScopes(clouddebugger.CloudDebuggerScope))
  27. //
  28. // To use an API key for authentication (note: some APIs do not support API keys), use option.WithAPIKey:
  29. //
  30. // clouddebuggerService, err := clouddebugger.NewService(ctx, option.WithAPIKey("AIza..."))
  31. //
  32. // To use an OAuth token (e.g., a user token obtained via a three-legged OAuth flow), use option.WithTokenSource:
  33. //
  34. // config := &oauth2.Config{...}
  35. // // ...
  36. // token, err := config.Exchange(ctx, ...)
  37. // clouddebuggerService, err := clouddebugger.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
  38. //
  39. // See https://godoc.org/google.golang.org/api/option/ for details on options.
  40. package clouddebugger // import "google.golang.org/api/clouddebugger/v2"
  41. import (
  42. "bytes"
  43. "context"
  44. "encoding/json"
  45. "errors"
  46. "fmt"
  47. "io"
  48. "net/http"
  49. "net/url"
  50. "strconv"
  51. "strings"
  52. gensupport "google.golang.org/api/gensupport"
  53. googleapi "google.golang.org/api/googleapi"
  54. option "google.golang.org/api/option"
  55. htransport "google.golang.org/api/transport/http"
  56. )
  57. // Always reference these packages, just in case the auto-generated code
  58. // below doesn't.
  59. var _ = bytes.NewBuffer
  60. var _ = strconv.Itoa
  61. var _ = fmt.Sprintf
  62. var _ = json.NewDecoder
  63. var _ = io.Copy
  64. var _ = url.Parse
  65. var _ = gensupport.MarshalJSON
  66. var _ = googleapi.Version
  67. var _ = errors.New
  68. var _ = strings.Replace
  69. var _ = context.Canceled
  70. const apiId = "clouddebugger:v2"
  71. const apiName = "clouddebugger"
  72. const apiVersion = "v2"
  73. const basePath = "https://clouddebugger.googleapis.com/"
  74. // OAuth2 scopes used by this API.
  75. const (
  76. // View and manage your data across Google Cloud Platform services
  77. CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
  78. // Use Stackdriver Debugger
  79. CloudDebuggerScope = "https://www.googleapis.com/auth/cloud_debugger"
  80. )
  81. // NewService creates a new Service.
  82. func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
  83. scopesOption := option.WithScopes(
  84. "https://www.googleapis.com/auth/cloud-platform",
  85. "https://www.googleapis.com/auth/cloud_debugger",
  86. )
  87. // NOTE: prepend, so we don't override user-specified scopes.
  88. opts = append([]option.ClientOption{scopesOption}, opts...)
  89. client, endpoint, err := htransport.NewClient(ctx, opts...)
  90. if err != nil {
  91. return nil, err
  92. }
  93. s, err := New(client)
  94. if err != nil {
  95. return nil, err
  96. }
  97. if endpoint != "" {
  98. s.BasePath = endpoint
  99. }
  100. return s, nil
  101. }
  102. // New creates a new Service. It uses the provided http.Client for requests.
  103. //
  104. // Deprecated: please use NewService instead.
  105. // To provide a custom HTTP client, use option.WithHTTPClient.
  106. // If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
  107. func New(client *http.Client) (*Service, error) {
  108. if client == nil {
  109. return nil, errors.New("client is nil")
  110. }
  111. s := &Service{client: client, BasePath: basePath}
  112. s.Controller = NewControllerService(s)
  113. s.Debugger = NewDebuggerService(s)
  114. return s, nil
  115. }
  116. type Service struct {
  117. client *http.Client
  118. BasePath string // API endpoint base URL
  119. UserAgent string // optional additional User-Agent fragment
  120. Controller *ControllerService
  121. Debugger *DebuggerService
  122. }
  123. func (s *Service) userAgent() string {
  124. if s.UserAgent == "" {
  125. return googleapi.UserAgent
  126. }
  127. return googleapi.UserAgent + " " + s.UserAgent
  128. }
  129. func NewControllerService(s *Service) *ControllerService {
  130. rs := &ControllerService{s: s}
  131. rs.Debuggees = NewControllerDebuggeesService(s)
  132. return rs
  133. }
  134. type ControllerService struct {
  135. s *Service
  136. Debuggees *ControllerDebuggeesService
  137. }
  138. func NewControllerDebuggeesService(s *Service) *ControllerDebuggeesService {
  139. rs := &ControllerDebuggeesService{s: s}
  140. rs.Breakpoints = NewControllerDebuggeesBreakpointsService(s)
  141. return rs
  142. }
  143. type ControllerDebuggeesService struct {
  144. s *Service
  145. Breakpoints *ControllerDebuggeesBreakpointsService
  146. }
  147. func NewControllerDebuggeesBreakpointsService(s *Service) *ControllerDebuggeesBreakpointsService {
  148. rs := &ControllerDebuggeesBreakpointsService{s: s}
  149. return rs
  150. }
  151. type ControllerDebuggeesBreakpointsService struct {
  152. s *Service
  153. }
  154. func NewDebuggerService(s *Service) *DebuggerService {
  155. rs := &DebuggerService{s: s}
  156. rs.Debuggees = NewDebuggerDebuggeesService(s)
  157. return rs
  158. }
  159. type DebuggerService struct {
  160. s *Service
  161. Debuggees *DebuggerDebuggeesService
  162. }
  163. func NewDebuggerDebuggeesService(s *Service) *DebuggerDebuggeesService {
  164. rs := &DebuggerDebuggeesService{s: s}
  165. rs.Breakpoints = NewDebuggerDebuggeesBreakpointsService(s)
  166. return rs
  167. }
  168. type DebuggerDebuggeesService struct {
  169. s *Service
  170. Breakpoints *DebuggerDebuggeesBreakpointsService
  171. }
  172. func NewDebuggerDebuggeesBreakpointsService(s *Service) *DebuggerDebuggeesBreakpointsService {
  173. rs := &DebuggerDebuggeesBreakpointsService{s: s}
  174. return rs
  175. }
  176. type DebuggerDebuggeesBreakpointsService struct {
  177. s *Service
  178. }
  179. // AliasContext: An alias to a repo revision.
  180. type AliasContext struct {
  181. // Kind: The alias kind.
  182. //
  183. // Possible values:
  184. // "ANY" - Do not use.
  185. // "FIXED" - Git tag
  186. // "MOVABLE" - Git branch
  187. // "OTHER" - OTHER is used to specify non-standard aliases, those not
  188. // of the kinds
  189. // above. For example, if a Git repo has a ref named "refs/foo/bar",
  190. // it
  191. // is considered to be of kind OTHER.
  192. Kind string `json:"kind,omitempty"`
  193. // Name: The alias name.
  194. Name string `json:"name,omitempty"`
  195. // ForceSendFields is a list of field names (e.g. "Kind") to
  196. // unconditionally include in API requests. By default, fields with
  197. // empty values are omitted from API requests. However, any non-pointer,
  198. // non-interface field appearing in ForceSendFields will be sent to the
  199. // server regardless of whether the field is empty or not. This may be
  200. // used to include empty fields in Patch requests.
  201. ForceSendFields []string `json:"-"`
  202. // NullFields is a list of field names (e.g. "Kind") to include in API
  203. // requests with the JSON null value. By default, fields with empty
  204. // values are omitted from API requests. However, any field with an
  205. // empty value appearing in NullFields will be sent to the server as
  206. // null. It is an error if a field in this list has a non-empty value.
  207. // This may be used to include null fields in Patch requests.
  208. NullFields []string `json:"-"`
  209. }
  210. func (s *AliasContext) MarshalJSON() ([]byte, error) {
  211. type NoMethod AliasContext
  212. raw := NoMethod(*s)
  213. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  214. }
  215. // Breakpoint: Represents the breakpoint specification, status and
  216. // results.
  217. type Breakpoint struct {
  218. // Action: Action that the agent should perform when the code at
  219. // the
  220. // breakpoint location is hit.
  221. //
  222. // Possible values:
  223. // "CAPTURE" - Capture stack frame and variables and update the
  224. // breakpoint.
  225. // The data is only captured once. After that the breakpoint is set
  226. // in a final state.
  227. // "LOG" - Log each breakpoint hit. The breakpoint remains active
  228. // until
  229. // deleted or expired.
  230. Action string `json:"action,omitempty"`
  231. // Condition: Condition that triggers the breakpoint.
  232. // The condition is a compound boolean expression composed using
  233. // expressions
  234. // in a programming language at the source location.
  235. Condition string `json:"condition,omitempty"`
  236. // CreateTime: Time this breakpoint was created by the server in seconds
  237. // resolution.
  238. CreateTime string `json:"createTime,omitempty"`
  239. // EvaluatedExpressions: Values of evaluated expressions at breakpoint
  240. // time.
  241. // The evaluated expressions appear in exactly the same order they
  242. // are listed in the `expressions` field.
  243. // The `name` field holds the original expression text, the `value`
  244. // or
  245. // `members` field holds the result of the evaluated expression.
  246. // If the expression cannot be evaluated, the `status` inside the
  247. // `Variable`
  248. // will indicate an error and contain the error text.
  249. EvaluatedExpressions []*Variable `json:"evaluatedExpressions,omitempty"`
  250. // Expressions: List of read-only expressions to evaluate at the
  251. // breakpoint location.
  252. // The expressions are composed using expressions in the programming
  253. // language
  254. // at the source location. If the breakpoint action is `LOG`, the
  255. // evaluated
  256. // expressions are included in log statements.
  257. Expressions []string `json:"expressions,omitempty"`
  258. // FinalTime: Time this breakpoint was finalized as seen by the server
  259. // in seconds
  260. // resolution.
  261. FinalTime string `json:"finalTime,omitempty"`
  262. // Id: Breakpoint identifier, unique in the scope of the debuggee.
  263. Id string `json:"id,omitempty"`
  264. // IsFinalState: When true, indicates that this is a final result and
  265. // the
  266. // breakpoint state will not change from here on.
  267. IsFinalState bool `json:"isFinalState,omitempty"`
  268. // Labels: A set of custom breakpoint properties, populated by the
  269. // agent, to be
  270. // displayed to the user.
  271. Labels map[string]string `json:"labels,omitempty"`
  272. // Location: Breakpoint source location.
  273. Location *SourceLocation `json:"location,omitempty"`
  274. // LogLevel: Indicates the severity of the log. Only relevant when
  275. // action is `LOG`.
  276. //
  277. // Possible values:
  278. // "INFO" - Information log message.
  279. // "WARNING" - Warning log message.
  280. // "ERROR" - Error log message.
  281. LogLevel string `json:"logLevel,omitempty"`
  282. // LogMessageFormat: Only relevant when action is `LOG`. Defines the
  283. // message to log when
  284. // the breakpoint hits. The message may include parameter placeholders
  285. // `$0`,
  286. // `$1`, etc. These placeholders are replaced with the evaluated
  287. // value
  288. // of the appropriate expression. Expressions not referenced
  289. // in
  290. // `log_message_format` are not logged.
  291. //
  292. // Example: `Message received, id = $0, count = $1` with
  293. // `expressions` = `[ message.id, message.count ]`.
  294. LogMessageFormat string `json:"logMessageFormat,omitempty"`
  295. // StackFrames: The stack at breakpoint time, where stack_frames[0]
  296. // represents the most
  297. // recently entered function.
  298. StackFrames []*StackFrame `json:"stackFrames,omitempty"`
  299. // Status: Breakpoint status.
  300. //
  301. // The status includes an error flag and a human readable message.
  302. // This field is usually unset. The message can be either
  303. // informational or an error message. Regardless, clients should
  304. // always
  305. // display the text message back to the user.
  306. //
  307. // Error status indicates complete failure of the breakpoint.
  308. //
  309. // Example (non-final state): `Still loading symbols...`
  310. //
  311. // Examples (final state):
  312. //
  313. // * `Invalid line number` referring to location
  314. // * `Field f not found in class C` referring to condition
  315. Status *StatusMessage `json:"status,omitempty"`
  316. // UserEmail: E-mail address of the user that created this breakpoint
  317. UserEmail string `json:"userEmail,omitempty"`
  318. // VariableTable: The `variable_table` exists to aid with computation,
  319. // memory and network
  320. // traffic optimization. It enables storing a variable once and
  321. // reference
  322. // it from multiple variables, including variables stored in
  323. // the
  324. // `variable_table` itself.
  325. // For example, the same `this` object, which may appear at many levels
  326. // of
  327. // the stack, can have all of its data stored once in this table.
  328. // The
  329. // stack frame variables then would hold only a reference to it.
  330. //
  331. // The variable `var_table_index` field is an index into this repeated
  332. // field.
  333. // The stored objects are nameless and get their name from the
  334. // referencing
  335. // variable. The effective variable is a merge of the referencing
  336. // variable
  337. // and the referenced variable.
  338. VariableTable []*Variable `json:"variableTable,omitempty"`
  339. // ForceSendFields is a list of field names (e.g. "Action") to
  340. // unconditionally include in API requests. By default, fields with
  341. // empty values are omitted from API requests. However, any non-pointer,
  342. // non-interface field appearing in ForceSendFields will be sent to the
  343. // server regardless of whether the field is empty or not. This may be
  344. // used to include empty fields in Patch requests.
  345. ForceSendFields []string `json:"-"`
  346. // NullFields is a list of field names (e.g. "Action") to include in API
  347. // requests with the JSON null value. By default, fields with empty
  348. // values are omitted from API requests. However, any field with an
  349. // empty value appearing in NullFields will be sent to the server as
  350. // null. It is an error if a field in this list has a non-empty value.
  351. // This may be used to include null fields in Patch requests.
  352. NullFields []string `json:"-"`
  353. }
  354. func (s *Breakpoint) MarshalJSON() ([]byte, error) {
  355. type NoMethod Breakpoint
  356. raw := NoMethod(*s)
  357. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  358. }
  359. // CloudRepoSourceContext: A CloudRepoSourceContext denotes a particular
  360. // revision in a cloud
  361. // repo (a repo hosted by the Google Cloud Platform).
  362. type CloudRepoSourceContext struct {
  363. // AliasContext: An alias, which may be a branch or tag.
  364. AliasContext *AliasContext `json:"aliasContext,omitempty"`
  365. // AliasName: The name of an alias (branch, tag, etc.).
  366. AliasName string `json:"aliasName,omitempty"`
  367. // RepoId: The ID of the repo.
  368. RepoId *RepoId `json:"repoId,omitempty"`
  369. // RevisionId: A revision ID.
  370. RevisionId string `json:"revisionId,omitempty"`
  371. // ForceSendFields is a list of field names (e.g. "AliasContext") to
  372. // unconditionally include in API requests. By default, fields with
  373. // empty values are omitted from API requests. However, any non-pointer,
  374. // non-interface field appearing in ForceSendFields will be sent to the
  375. // server regardless of whether the field is empty or not. This may be
  376. // used to include empty fields in Patch requests.
  377. ForceSendFields []string `json:"-"`
  378. // NullFields is a list of field names (e.g. "AliasContext") to include
  379. // in API requests with the JSON null value. By default, fields with
  380. // empty values are omitted from API requests. However, any field with
  381. // an empty value appearing in NullFields will be sent to the server as
  382. // null. It is an error if a field in this list has a non-empty value.
  383. // This may be used to include null fields in Patch requests.
  384. NullFields []string `json:"-"`
  385. }
  386. func (s *CloudRepoSourceContext) MarshalJSON() ([]byte, error) {
  387. type NoMethod CloudRepoSourceContext
  388. raw := NoMethod(*s)
  389. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  390. }
  391. // CloudWorkspaceId: A CloudWorkspaceId is a unique identifier for a
  392. // cloud workspace.
  393. // A cloud workspace is a place associated with a repo where modified
  394. // files
  395. // can be stored before they are committed.
  396. type CloudWorkspaceId struct {
  397. // Name: The unique name of the workspace within the repo. This is the
  398. // name
  399. // chosen by the client in the Source API's CreateWorkspace method.
  400. Name string `json:"name,omitempty"`
  401. // RepoId: The ID of the repo containing the workspace.
  402. RepoId *RepoId `json:"repoId,omitempty"`
  403. // ForceSendFields is a list of field names (e.g. "Name") to
  404. // unconditionally include in API requests. By default, fields with
  405. // empty values are omitted from API requests. However, any non-pointer,
  406. // non-interface field appearing in ForceSendFields will be sent to the
  407. // server regardless of whether the field is empty or not. This may be
  408. // used to include empty fields in Patch requests.
  409. ForceSendFields []string `json:"-"`
  410. // NullFields is a list of field names (e.g. "Name") to include in API
  411. // requests with the JSON null value. By default, fields with empty
  412. // values are omitted from API requests. However, any field with an
  413. // empty value appearing in NullFields will be sent to the server as
  414. // null. It is an error if a field in this list has a non-empty value.
  415. // This may be used to include null fields in Patch requests.
  416. NullFields []string `json:"-"`
  417. }
  418. func (s *CloudWorkspaceId) MarshalJSON() ([]byte, error) {
  419. type NoMethod CloudWorkspaceId
  420. raw := NoMethod(*s)
  421. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  422. }
  423. // CloudWorkspaceSourceContext: A CloudWorkspaceSourceContext denotes a
  424. // workspace at a particular snapshot.
  425. type CloudWorkspaceSourceContext struct {
  426. // SnapshotId: The ID of the snapshot.
  427. // An empty snapshot_id refers to the most recent snapshot.
  428. SnapshotId string `json:"snapshotId,omitempty"`
  429. // WorkspaceId: The ID of the workspace.
  430. WorkspaceId *CloudWorkspaceId `json:"workspaceId,omitempty"`
  431. // ForceSendFields is a list of field names (e.g. "SnapshotId") to
  432. // unconditionally include in API requests. By default, fields with
  433. // empty values are omitted from API requests. However, any non-pointer,
  434. // non-interface field appearing in ForceSendFields will be sent to the
  435. // server regardless of whether the field is empty or not. This may be
  436. // used to include empty fields in Patch requests.
  437. ForceSendFields []string `json:"-"`
  438. // NullFields is a list of field names (e.g. "SnapshotId") to include in
  439. // API requests with the JSON null value. By default, fields with empty
  440. // values are omitted from API requests. However, any field with an
  441. // empty value appearing in NullFields will be sent to the server as
  442. // null. It is an error if a field in this list has a non-empty value.
  443. // This may be used to include null fields in Patch requests.
  444. NullFields []string `json:"-"`
  445. }
  446. func (s *CloudWorkspaceSourceContext) MarshalJSON() ([]byte, error) {
  447. type NoMethod CloudWorkspaceSourceContext
  448. raw := NoMethod(*s)
  449. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  450. }
  451. // Debuggee: Represents the debugged application. The application may
  452. // include one or more
  453. // replicated processes executing the same code. Each of these processes
  454. // is
  455. // attached with a debugger agent, carrying out the debugging
  456. // commands.
  457. // Agents attached to the same debuggee identify themselves as such by
  458. // using
  459. // exactly the same Debuggee message value when registering.
  460. type Debuggee struct {
  461. // AgentVersion: Version ID of the agent.
  462. // Schema: `domain/language-platform/vmajor.minor` (for
  463. // example
  464. // `google.com/java-gcp/v1.1`).
  465. AgentVersion string `json:"agentVersion,omitempty"`
  466. // Description: Human readable description of the debuggee.
  467. // Including a human-readable project name, environment name and
  468. // version
  469. // information is recommended.
  470. Description string `json:"description,omitempty"`
  471. // ExtSourceContexts: References to the locations and revisions of the
  472. // source code used in the
  473. // deployed application.
  474. ExtSourceContexts []*ExtendedSourceContext `json:"extSourceContexts,omitempty"`
  475. // Id: Unique identifier for the debuggee generated by the controller
  476. // service.
  477. Id string `json:"id,omitempty"`
  478. // IsDisabled: If set to `true`, indicates that the agent should disable
  479. // itself and
  480. // detach from the debuggee.
  481. IsDisabled bool `json:"isDisabled,omitempty"`
  482. // IsInactive: If set to `true`, indicates that Controller service does
  483. // not detect any
  484. // activity from the debuggee agents and the application is possibly
  485. // stopped.
  486. IsInactive bool `json:"isInactive,omitempty"`
  487. // Labels: A set of custom debuggee properties, populated by the agent,
  488. // to be
  489. // displayed to the user.
  490. Labels map[string]string `json:"labels,omitempty"`
  491. // Project: Project the debuggee is associated with.
  492. // Use project number or id when registering a Google Cloud Platform
  493. // project.
  494. Project string `json:"project,omitempty"`
  495. // SourceContexts: References to the locations and revisions of the
  496. // source code used in the
  497. // deployed application.
  498. SourceContexts []*SourceContext `json:"sourceContexts,omitempty"`
  499. // Status: Human readable message to be displayed to the user about this
  500. // debuggee.
  501. // Absence of this field indicates no status. The message can be
  502. // either
  503. // informational or an error status.
  504. Status *StatusMessage `json:"status,omitempty"`
  505. // Uniquifier: Uniquifier to further distinguish the application.
  506. // It is possible that different applications might have identical
  507. // values in
  508. // the debuggee message, thus, incorrectly identified as a single
  509. // application
  510. // by the Controller service. This field adds salt to further
  511. // distinguish the
  512. // application. Agents should consider seeding this field with value
  513. // that
  514. // identifies the code, binary, configuration and environment.
  515. Uniquifier string `json:"uniquifier,omitempty"`
  516. // ForceSendFields is a list of field names (e.g. "AgentVersion") to
  517. // unconditionally include in API requests. By default, fields with
  518. // empty values are omitted from API requests. However, any non-pointer,
  519. // non-interface field appearing in ForceSendFields will be sent to the
  520. // server regardless of whether the field is empty or not. This may be
  521. // used to include empty fields in Patch requests.
  522. ForceSendFields []string `json:"-"`
  523. // NullFields is a list of field names (e.g. "AgentVersion") to include
  524. // in API requests with the JSON null value. By default, fields with
  525. // empty values are omitted from API requests. However, any field with
  526. // an empty value appearing in NullFields will be sent to the server as
  527. // null. It is an error if a field in this list has a non-empty value.
  528. // This may be used to include null fields in Patch requests.
  529. NullFields []string `json:"-"`
  530. }
  531. func (s *Debuggee) MarshalJSON() ([]byte, error) {
  532. type NoMethod Debuggee
  533. raw := NoMethod(*s)
  534. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  535. }
  536. // Empty: A generic empty message that you can re-use to avoid defining
  537. // duplicated
  538. // empty messages in your APIs. A typical example is to use it as the
  539. // request
  540. // or the response type of an API method. For instance:
  541. //
  542. // service Foo {
  543. // rpc Bar(google.protobuf.Empty) returns
  544. // (google.protobuf.Empty);
  545. // }
  546. //
  547. // The JSON representation for `Empty` is empty JSON object `{}`.
  548. type Empty struct {
  549. // ServerResponse contains the HTTP response code and headers from the
  550. // server.
  551. googleapi.ServerResponse `json:"-"`
  552. }
  553. // ExtendedSourceContext: An ExtendedSourceContext is a SourceContext
  554. // combined with additional
  555. // details describing the context.
  556. type ExtendedSourceContext struct {
  557. // Context: Any source context.
  558. Context *SourceContext `json:"context,omitempty"`
  559. // Labels: Labels with user defined metadata.
  560. Labels map[string]string `json:"labels,omitempty"`
  561. // ForceSendFields is a list of field names (e.g. "Context") to
  562. // unconditionally include in API requests. By default, fields with
  563. // empty values are omitted from API requests. However, any non-pointer,
  564. // non-interface field appearing in ForceSendFields will be sent to the
  565. // server regardless of whether the field is empty or not. This may be
  566. // used to include empty fields in Patch requests.
  567. ForceSendFields []string `json:"-"`
  568. // NullFields is a list of field names (e.g. "Context") to include in
  569. // API requests with the JSON null value. By default, fields with empty
  570. // values are omitted from API requests. However, any field with an
  571. // empty value appearing in NullFields will be sent to the server as
  572. // null. It is an error if a field in this list has a non-empty value.
  573. // This may be used to include null fields in Patch requests.
  574. NullFields []string `json:"-"`
  575. }
  576. func (s *ExtendedSourceContext) MarshalJSON() ([]byte, error) {
  577. type NoMethod ExtendedSourceContext
  578. raw := NoMethod(*s)
  579. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  580. }
  581. // FormatMessage: Represents a message with parameters.
  582. type FormatMessage struct {
  583. // Format: Format template for the message. The `format` uses
  584. // placeholders `$0`,
  585. // `$1`, etc. to reference parameters. `$$` can be used to denote the
  586. // `$`
  587. // character.
  588. //
  589. // Examples:
  590. //
  591. // * `Failed to load '$0' which helps debug $1 the first time it
  592. // is loaded. Again, $0 is very important.`
  593. // * `Please pay $$10 to use $0 instead of $1.`
  594. Format string `json:"format,omitempty"`
  595. // Parameters: Optional parameters to be embedded into the message.
  596. Parameters []string `json:"parameters,omitempty"`
  597. // ForceSendFields is a list of field names (e.g. "Format") to
  598. // unconditionally include in API requests. By default, fields with
  599. // empty values are omitted from API requests. However, any non-pointer,
  600. // non-interface field appearing in ForceSendFields will be sent to the
  601. // server regardless of whether the field is empty or not. This may be
  602. // used to include empty fields in Patch requests.
  603. ForceSendFields []string `json:"-"`
  604. // NullFields is a list of field names (e.g. "Format") to include in API
  605. // requests with the JSON null value. By default, fields with empty
  606. // values are omitted from API requests. However, any field with an
  607. // empty value appearing in NullFields will be sent to the server as
  608. // null. It is an error if a field in this list has a non-empty value.
  609. // This may be used to include null fields in Patch requests.
  610. NullFields []string `json:"-"`
  611. }
  612. func (s *FormatMessage) MarshalJSON() ([]byte, error) {
  613. type NoMethod FormatMessage
  614. raw := NoMethod(*s)
  615. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  616. }
  617. // GerritSourceContext: A SourceContext referring to a Gerrit project.
  618. type GerritSourceContext struct {
  619. // AliasContext: An alias, which may be a branch or tag.
  620. AliasContext *AliasContext `json:"aliasContext,omitempty"`
  621. // AliasName: The name of an alias (branch, tag, etc.).
  622. AliasName string `json:"aliasName,omitempty"`
  623. // GerritProject: The full project name within the host. Projects may be
  624. // nested, so
  625. // "project/subproject" is a valid project name.
  626. // The "repo name" is hostURI/project.
  627. GerritProject string `json:"gerritProject,omitempty"`
  628. // HostUri: The URI of a running Gerrit instance.
  629. HostUri string `json:"hostUri,omitempty"`
  630. // RevisionId: A revision (commit) ID.
  631. RevisionId string `json:"revisionId,omitempty"`
  632. // ForceSendFields is a list of field names (e.g. "AliasContext") to
  633. // unconditionally include in API requests. By default, fields with
  634. // empty values are omitted from API requests. However, any non-pointer,
  635. // non-interface field appearing in ForceSendFields will be sent to the
  636. // server regardless of whether the field is empty or not. This may be
  637. // used to include empty fields in Patch requests.
  638. ForceSendFields []string `json:"-"`
  639. // NullFields is a list of field names (e.g. "AliasContext") to include
  640. // in API requests with the JSON null value. By default, fields with
  641. // empty values are omitted from API requests. However, any field with
  642. // an empty value appearing in NullFields will be sent to the server as
  643. // null. It is an error if a field in this list has a non-empty value.
  644. // This may be used to include null fields in Patch requests.
  645. NullFields []string `json:"-"`
  646. }
  647. func (s *GerritSourceContext) MarshalJSON() ([]byte, error) {
  648. type NoMethod GerritSourceContext
  649. raw := NoMethod(*s)
  650. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  651. }
  652. // GetBreakpointResponse: Response for getting breakpoint information.
  653. type GetBreakpointResponse struct {
  654. // Breakpoint: Complete breakpoint state.
  655. // The fields `id` and `location` are guaranteed to be set.
  656. Breakpoint *Breakpoint `json:"breakpoint,omitempty"`
  657. // ServerResponse contains the HTTP response code and headers from the
  658. // server.
  659. googleapi.ServerResponse `json:"-"`
  660. // ForceSendFields is a list of field names (e.g. "Breakpoint") to
  661. // unconditionally include in API requests. By default, fields with
  662. // empty values are omitted from API requests. However, any non-pointer,
  663. // non-interface field appearing in ForceSendFields will be sent to the
  664. // server regardless of whether the field is empty or not. This may be
  665. // used to include empty fields in Patch requests.
  666. ForceSendFields []string `json:"-"`
  667. // NullFields is a list of field names (e.g. "Breakpoint") to include in
  668. // API requests with the JSON null value. By default, fields with empty
  669. // values are omitted from API requests. However, any field with an
  670. // empty value appearing in NullFields will be sent to the server as
  671. // null. It is an error if a field in this list has a non-empty value.
  672. // This may be used to include null fields in Patch requests.
  673. NullFields []string `json:"-"`
  674. }
  675. func (s *GetBreakpointResponse) MarshalJSON() ([]byte, error) {
  676. type NoMethod GetBreakpointResponse
  677. raw := NoMethod(*s)
  678. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  679. }
  680. // GitSourceContext: A GitSourceContext denotes a particular revision in
  681. // a third party Git
  682. // repository (e.g. GitHub).
  683. type GitSourceContext struct {
  684. // RevisionId: Git commit hash.
  685. // required.
  686. RevisionId string `json:"revisionId,omitempty"`
  687. // Url: Git repository URL.
  688. Url string `json:"url,omitempty"`
  689. // ForceSendFields is a list of field names (e.g. "RevisionId") to
  690. // unconditionally include in API requests. By default, fields with
  691. // empty values are omitted from API requests. However, any non-pointer,
  692. // non-interface field appearing in ForceSendFields will be sent to the
  693. // server regardless of whether the field is empty or not. This may be
  694. // used to include empty fields in Patch requests.
  695. ForceSendFields []string `json:"-"`
  696. // NullFields is a list of field names (e.g. "RevisionId") to include in
  697. // API requests with the JSON null value. By default, fields with empty
  698. // values are omitted from API requests. However, any field with an
  699. // empty value appearing in NullFields will be sent to the server as
  700. // null. It is an error if a field in this list has a non-empty value.
  701. // This may be used to include null fields in Patch requests.
  702. NullFields []string `json:"-"`
  703. }
  704. func (s *GitSourceContext) MarshalJSON() ([]byte, error) {
  705. type NoMethod GitSourceContext
  706. raw := NoMethod(*s)
  707. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  708. }
  709. // ListActiveBreakpointsResponse: Response for listing active
  710. // breakpoints.
  711. type ListActiveBreakpointsResponse struct {
  712. // Breakpoints: List of all active breakpoints.
  713. // The fields `id` and `location` are guaranteed to be set on each
  714. // breakpoint.
  715. Breakpoints []*Breakpoint `json:"breakpoints,omitempty"`
  716. // NextWaitToken: A token that can be used in the next method call to
  717. // block until
  718. // the list of breakpoints changes.
  719. NextWaitToken string `json:"nextWaitToken,omitempty"`
  720. // WaitExpired: If set to `true`, indicates that there is no change to
  721. // the
  722. // list of active breakpoints and the server-selected timeout has
  723. // expired.
  724. // The `breakpoints` field would be empty and should be ignored.
  725. WaitExpired bool `json:"waitExpired,omitempty"`
  726. // ServerResponse contains the HTTP response code and headers from the
  727. // server.
  728. googleapi.ServerResponse `json:"-"`
  729. // ForceSendFields is a list of field names (e.g. "Breakpoints") to
  730. // unconditionally include in API requests. By default, fields with
  731. // empty values are omitted from API requests. However, any non-pointer,
  732. // non-interface field appearing in ForceSendFields will be sent to the
  733. // server regardless of whether the field is empty or not. This may be
  734. // used to include empty fields in Patch requests.
  735. ForceSendFields []string `json:"-"`
  736. // NullFields is a list of field names (e.g. "Breakpoints") to include
  737. // in API requests with the JSON null value. By default, fields with
  738. // empty values are omitted from API requests. However, any field with
  739. // an empty value appearing in NullFields will be sent to the server as
  740. // null. It is an error if a field in this list has a non-empty value.
  741. // This may be used to include null fields in Patch requests.
  742. NullFields []string `json:"-"`
  743. }
  744. func (s *ListActiveBreakpointsResponse) MarshalJSON() ([]byte, error) {
  745. type NoMethod ListActiveBreakpointsResponse
  746. raw := NoMethod(*s)
  747. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  748. }
  749. // ListBreakpointsResponse: Response for listing breakpoints.
  750. type ListBreakpointsResponse struct {
  751. // Breakpoints: List of breakpoints matching the request.
  752. // The fields `id` and `location` are guaranteed to be set on each
  753. // breakpoint.
  754. // The fields: `stack_frames`, `evaluated_expressions` and
  755. // `variable_table`
  756. // are cleared on each breakpoint regardless of its status.
  757. Breakpoints []*Breakpoint `json:"breakpoints,omitempty"`
  758. // NextWaitToken: A wait token that can be used in the next call to
  759. // `list` (REST) or
  760. // `ListBreakpoints` (RPC) to block until the list of breakpoints has
  761. // changes.
  762. NextWaitToken string `json:"nextWaitToken,omitempty"`
  763. // ServerResponse contains the HTTP response code and headers from the
  764. // server.
  765. googleapi.ServerResponse `json:"-"`
  766. // ForceSendFields is a list of field names (e.g. "Breakpoints") to
  767. // unconditionally include in API requests. By default, fields with
  768. // empty values are omitted from API requests. However, any non-pointer,
  769. // non-interface field appearing in ForceSendFields will be sent to the
  770. // server regardless of whether the field is empty or not. This may be
  771. // used to include empty fields in Patch requests.
  772. ForceSendFields []string `json:"-"`
  773. // NullFields is a list of field names (e.g. "Breakpoints") to include
  774. // in API requests with the JSON null value. By default, fields with
  775. // empty values are omitted from API requests. However, any field with
  776. // an empty value appearing in NullFields will be sent to the server as
  777. // null. It is an error if a field in this list has a non-empty value.
  778. // This may be used to include null fields in Patch requests.
  779. NullFields []string `json:"-"`
  780. }
  781. func (s *ListBreakpointsResponse) MarshalJSON() ([]byte, error) {
  782. type NoMethod ListBreakpointsResponse
  783. raw := NoMethod(*s)
  784. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  785. }
  786. // ListDebuggeesResponse: Response for listing debuggees.
  787. type ListDebuggeesResponse struct {
  788. // Debuggees: List of debuggees accessible to the calling user.
  789. // The fields `debuggee.id` and `description` are guaranteed to be
  790. // set.
  791. // The `description` field is a human readable field provided by agents
  792. // and
  793. // can be displayed to users.
  794. Debuggees []*Debuggee `json:"debuggees,omitempty"`
  795. // ServerResponse contains the HTTP response code and headers from the
  796. // server.
  797. googleapi.ServerResponse `json:"-"`
  798. // ForceSendFields is a list of field names (e.g. "Debuggees") to
  799. // unconditionally include in API requests. By default, fields with
  800. // empty values are omitted from API requests. However, any non-pointer,
  801. // non-interface field appearing in ForceSendFields will be sent to the
  802. // server regardless of whether the field is empty or not. This may be
  803. // used to include empty fields in Patch requests.
  804. ForceSendFields []string `json:"-"`
  805. // NullFields is a list of field names (e.g. "Debuggees") to include in
  806. // API requests with the JSON null value. By default, fields with empty
  807. // values are omitted from API requests. However, any field with an
  808. // empty value appearing in NullFields will be sent to the server as
  809. // null. It is an error if a field in this list has a non-empty value.
  810. // This may be used to include null fields in Patch requests.
  811. NullFields []string `json:"-"`
  812. }
  813. func (s *ListDebuggeesResponse) MarshalJSON() ([]byte, error) {
  814. type NoMethod ListDebuggeesResponse
  815. raw := NoMethod(*s)
  816. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  817. }
  818. // ProjectRepoId: Selects a repo using a Google Cloud Platform project
  819. // ID
  820. // (e.g. winged-cargo-31) and a repo name within that project.
  821. type ProjectRepoId struct {
  822. // ProjectId: The ID of the project.
  823. ProjectId string `json:"projectId,omitempty"`
  824. // RepoName: The name of the repo. Leave empty for the default repo.
  825. RepoName string `json:"repoName,omitempty"`
  826. // ForceSendFields is a list of field names (e.g. "ProjectId") to
  827. // unconditionally include in API requests. By default, fields with
  828. // empty values are omitted from API requests. However, any non-pointer,
  829. // non-interface field appearing in ForceSendFields will be sent to the
  830. // server regardless of whether the field is empty or not. This may be
  831. // used to include empty fields in Patch requests.
  832. ForceSendFields []string `json:"-"`
  833. // NullFields is a list of field names (e.g. "ProjectId") to include in
  834. // API requests with the JSON null value. By default, fields with empty
  835. // values are omitted from API requests. However, any field with an
  836. // empty value appearing in NullFields will be sent to the server as
  837. // null. It is an error if a field in this list has a non-empty value.
  838. // This may be used to include null fields in Patch requests.
  839. NullFields []string `json:"-"`
  840. }
  841. func (s *ProjectRepoId) MarshalJSON() ([]byte, error) {
  842. type NoMethod ProjectRepoId
  843. raw := NoMethod(*s)
  844. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  845. }
  846. // RegisterDebuggeeRequest: Request to register a debuggee.
  847. type RegisterDebuggeeRequest struct {
  848. // Debuggee: Debuggee information to register.
  849. // The fields `project`, `uniquifier`, `description` and
  850. // `agent_version`
  851. // of the debuggee must be set.
  852. Debuggee *Debuggee `json:"debuggee,omitempty"`
  853. // ForceSendFields is a list of field names (e.g. "Debuggee") to
  854. // unconditionally include in API requests. By default, fields with
  855. // empty values are omitted from API requests. However, any non-pointer,
  856. // non-interface field appearing in ForceSendFields will be sent to the
  857. // server regardless of whether the field is empty or not. This may be
  858. // used to include empty fields in Patch requests.
  859. ForceSendFields []string `json:"-"`
  860. // NullFields is a list of field names (e.g. "Debuggee") to include in
  861. // API requests with the JSON null value. By default, fields with empty
  862. // values are omitted from API requests. However, any field with an
  863. // empty value appearing in NullFields will be sent to the server as
  864. // null. It is an error if a field in this list has a non-empty value.
  865. // This may be used to include null fields in Patch requests.
  866. NullFields []string `json:"-"`
  867. }
  868. func (s *RegisterDebuggeeRequest) MarshalJSON() ([]byte, error) {
  869. type NoMethod RegisterDebuggeeRequest
  870. raw := NoMethod(*s)
  871. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  872. }
  873. // RegisterDebuggeeResponse: Response for registering a debuggee.
  874. type RegisterDebuggeeResponse struct {
  875. // Debuggee: Debuggee resource.
  876. // The field `id` is guaranteed to be set (in addition to the echoed
  877. // fields).
  878. // If the field `is_disabled` is set to `true`, the agent should
  879. // disable
  880. // itself by removing all breakpoints and detaching from the
  881. // application.
  882. // It should however continue to poll `RegisterDebuggee` until
  883. // reenabled.
  884. Debuggee *Debuggee `json:"debuggee,omitempty"`
  885. // ServerResponse contains the HTTP response code and headers from the
  886. // server.
  887. googleapi.ServerResponse `json:"-"`
  888. // ForceSendFields is a list of field names (e.g. "Debuggee") to
  889. // unconditionally include in API requests. By default, fields with
  890. // empty values are omitted from API requests. However, any non-pointer,
  891. // non-interface field appearing in ForceSendFields will be sent to the
  892. // server regardless of whether the field is empty or not. This may be
  893. // used to include empty fields in Patch requests.
  894. ForceSendFields []string `json:"-"`
  895. // NullFields is a list of field names (e.g. "Debuggee") to include in
  896. // API requests with the JSON null value. By default, fields with empty
  897. // values are omitted from API requests. However, any field with an
  898. // empty value appearing in NullFields will be sent to the server as
  899. // null. It is an error if a field in this list has a non-empty value.
  900. // This may be used to include null fields in Patch requests.
  901. NullFields []string `json:"-"`
  902. }
  903. func (s *RegisterDebuggeeResponse) MarshalJSON() ([]byte, error) {
  904. type NoMethod RegisterDebuggeeResponse
  905. raw := NoMethod(*s)
  906. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  907. }
  908. // RepoId: A unique identifier for a cloud repo.
  909. type RepoId struct {
  910. // ProjectRepoId: A combination of a project ID and a repo name.
  911. ProjectRepoId *ProjectRepoId `json:"projectRepoId,omitempty"`
  912. // Uid: A server-assigned, globally unique identifier.
  913. Uid string `json:"uid,omitempty"`
  914. // ForceSendFields is a list of field names (e.g. "ProjectRepoId") to
  915. // unconditionally include in API requests. By default, fields with
  916. // empty values are omitted from API requests. However, any non-pointer,
  917. // non-interface field appearing in ForceSendFields will be sent to the
  918. // server regardless of whether the field is empty or not. This may be
  919. // used to include empty fields in Patch requests.
  920. ForceSendFields []string `json:"-"`
  921. // NullFields is a list of field names (e.g. "ProjectRepoId") to include
  922. // in API requests with the JSON null value. By default, fields with
  923. // empty values are omitted from API requests. However, any field with
  924. // an empty value appearing in NullFields will be sent to the server as
  925. // null. It is an error if a field in this list has a non-empty value.
  926. // This may be used to include null fields in Patch requests.
  927. NullFields []string `json:"-"`
  928. }
  929. func (s *RepoId) MarshalJSON() ([]byte, error) {
  930. type NoMethod RepoId
  931. raw := NoMethod(*s)
  932. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  933. }
  934. // SetBreakpointResponse: Response for setting a breakpoint.
  935. type SetBreakpointResponse struct {
  936. // Breakpoint: Breakpoint resource.
  937. // The field `id` is guaranteed to be set (in addition to the echoed
  938. // fileds).
  939. Breakpoint *Breakpoint `json:"breakpoint,omitempty"`
  940. // ServerResponse contains the HTTP response code and headers from the
  941. // server.
  942. googleapi.ServerResponse `json:"-"`
  943. // ForceSendFields is a list of field names (e.g. "Breakpoint") to
  944. // unconditionally include in API requests. By default, fields with
  945. // empty values are omitted from API requests. However, any non-pointer,
  946. // non-interface field appearing in ForceSendFields will be sent to the
  947. // server regardless of whether the field is empty or not. This may be
  948. // used to include empty fields in Patch requests.
  949. ForceSendFields []string `json:"-"`
  950. // NullFields is a list of field names (e.g. "Breakpoint") to include in
  951. // API requests with the JSON null value. By default, fields with empty
  952. // values are omitted from API requests. However, any field with an
  953. // empty value appearing in NullFields will be sent to the server as
  954. // null. It is an error if a field in this list has a non-empty value.
  955. // This may be used to include null fields in Patch requests.
  956. NullFields []string `json:"-"`
  957. }
  958. func (s *SetBreakpointResponse) MarshalJSON() ([]byte, error) {
  959. type NoMethod SetBreakpointResponse
  960. raw := NoMethod(*s)
  961. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  962. }
  963. // SourceContext: A SourceContext is a reference to a tree of files. A
  964. // SourceContext together
  965. // with a path point to a unique revision of a single file or directory.
  966. type SourceContext struct {
  967. // CloudRepo: A SourceContext referring to a revision in a cloud repo.
  968. CloudRepo *CloudRepoSourceContext `json:"cloudRepo,omitempty"`
  969. // CloudWorkspace: A SourceContext referring to a snapshot in a cloud
  970. // workspace.
  971. CloudWorkspace *CloudWorkspaceSourceContext `json:"cloudWorkspace,omitempty"`
  972. // Gerrit: A SourceContext referring to a Gerrit project.
  973. Gerrit *GerritSourceContext `json:"gerrit,omitempty"`
  974. // Git: A SourceContext referring to any third party Git repo (e.g.
  975. // GitHub).
  976. Git *GitSourceContext `json:"git,omitempty"`
  977. // ForceSendFields is a list of field names (e.g. "CloudRepo") to
  978. // unconditionally include in API requests. By default, fields with
  979. // empty values are omitted from API requests. However, any non-pointer,
  980. // non-interface field appearing in ForceSendFields will be sent to the
  981. // server regardless of whether the field is empty or not. This may be
  982. // used to include empty fields in Patch requests.
  983. ForceSendFields []string `json:"-"`
  984. // NullFields is a list of field names (e.g. "CloudRepo") to include in
  985. // API requests with the JSON null value. By default, fields with empty
  986. // values are omitted from API requests. However, any field with an
  987. // empty value appearing in NullFields will be sent to the server as
  988. // null. It is an error if a field in this list has a non-empty value.
  989. // This may be used to include null fields in Patch requests.
  990. NullFields []string `json:"-"`
  991. }
  992. func (s *SourceContext) MarshalJSON() ([]byte, error) {
  993. type NoMethod SourceContext
  994. raw := NoMethod(*s)
  995. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  996. }
  997. // SourceLocation: Represents a location in the source code.
  998. type SourceLocation struct {
  999. // Column: Column within a line. The first column in a line as the value
  1000. // `1`.
  1001. // Agents that do not support setting breakpoints on specific columns
  1002. // ignore
  1003. // this field.
  1004. Column int64 `json:"column,omitempty"`
  1005. // Line: Line inside the file. The first line in the file has the value
  1006. // `1`.
  1007. Line int64 `json:"line,omitempty"`
  1008. // Path: Path to the source file within the source context of the target
  1009. // binary.
  1010. Path string `json:"path,omitempty"`
  1011. // ForceSendFields is a list of field names (e.g. "Column") to
  1012. // unconditionally include in API requests. By default, fields with
  1013. // empty values are omitted from API requests. However, any non-pointer,
  1014. // non-interface field appearing in ForceSendFields will be sent to the
  1015. // server regardless of whether the field is empty or not. This may be
  1016. // used to include empty fields in Patch requests.
  1017. ForceSendFields []string `json:"-"`
  1018. // NullFields is a list of field names (e.g. "Column") to include in API
  1019. // requests with the JSON null value. By default, fields with empty
  1020. // values are omitted from API requests. However, any field with an
  1021. // empty value appearing in NullFields will be sent to the server as
  1022. // null. It is an error if a field in this list has a non-empty value.
  1023. // This may be used to include null fields in Patch requests.
  1024. NullFields []string `json:"-"`
  1025. }
  1026. func (s *SourceLocation) MarshalJSON() ([]byte, error) {
  1027. type NoMethod SourceLocation
  1028. raw := NoMethod(*s)
  1029. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1030. }
  1031. // StackFrame: Represents a stack frame context.
  1032. type StackFrame struct {
  1033. // Arguments: Set of arguments passed to this function.
  1034. // Note that this might not be populated for all stack frames.
  1035. Arguments []*Variable `json:"arguments,omitempty"`
  1036. // Function: Demangled function name at the call site.
  1037. Function string `json:"function,omitempty"`
  1038. // Locals: Set of local variables at the stack frame location.
  1039. // Note that this might not be populated for all stack frames.
  1040. Locals []*Variable `json:"locals,omitempty"`
  1041. // Location: Source location of the call site.
  1042. Location *SourceLocation `json:"location,omitempty"`
  1043. // ForceSendFields is a list of field names (e.g. "Arguments") to
  1044. // unconditionally include in API requests. By default, fields with
  1045. // empty values are omitted from API requests. However, any non-pointer,
  1046. // non-interface field appearing in ForceSendFields will be sent to the
  1047. // server regardless of whether the field is empty or not. This may be
  1048. // used to include empty fields in Patch requests.
  1049. ForceSendFields []string `json:"-"`
  1050. // NullFields is a list of field names (e.g. "Arguments") to include in
  1051. // API requests with the JSON null value. By default, fields with empty
  1052. // values are omitted from API requests. However, any field with an
  1053. // empty value appearing in NullFields will be sent to the server as
  1054. // null. It is an error if a field in this list has a non-empty value.
  1055. // This may be used to include null fields in Patch requests.
  1056. NullFields []string `json:"-"`
  1057. }
  1058. func (s *StackFrame) MarshalJSON() ([]byte, error) {
  1059. type NoMethod StackFrame
  1060. raw := NoMethod(*s)
  1061. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1062. }
  1063. // StatusMessage: Represents a contextual status message.
  1064. // The message can indicate an error or informational status, and refer
  1065. // to
  1066. // specific parts of the containing object.
  1067. // For example, the `Breakpoint.status` field can indicate an error
  1068. // referring
  1069. // to the `BREAKPOINT_SOURCE_LOCATION` with the message `Location not
  1070. // found`.
  1071. type StatusMessage struct {
  1072. // Description: Status message text.
  1073. Description *FormatMessage `json:"description,omitempty"`
  1074. // IsError: Distinguishes errors from informational messages.
  1075. IsError bool `json:"isError,omitempty"`
  1076. // RefersTo: Reference to which the message applies.
  1077. //
  1078. // Possible values:
  1079. // "UNSPECIFIED" - Status doesn't refer to any particular input.
  1080. // "BREAKPOINT_SOURCE_LOCATION" - Status applies to the breakpoint and
  1081. // is related to its location.
  1082. // "BREAKPOINT_CONDITION" - Status applies to the breakpoint and is
  1083. // related to its condition.
  1084. // "BREAKPOINT_EXPRESSION" - Status applies to the breakpoint and is
  1085. // related to its expressions.
  1086. // "BREAKPOINT_AGE" - Status applies to the breakpoint and is related
  1087. // to its age.
  1088. // "VARIABLE_NAME" - Status applies to the entire variable.
  1089. // "VARIABLE_VALUE" - Status applies to variable value (variable name
  1090. // is valid).
  1091. RefersTo string `json:"refersTo,omitempty"`
  1092. // ForceSendFields is a list of field names (e.g. "Description") to
  1093. // unconditionally include in API requests. By default, fields with
  1094. // empty values are omitted from API requests. However, any non-pointer,
  1095. // non-interface field appearing in ForceSendFields will be sent to the
  1096. // server regardless of whether the field is empty or not. This may be
  1097. // used to include empty fields in Patch requests.
  1098. ForceSendFields []string `json:"-"`
  1099. // NullFields is a list of field names (e.g. "Description") to include
  1100. // in API requests with the JSON null value. By default, fields with
  1101. // empty values are omitted from API requests. However, any field with
  1102. // an empty value appearing in NullFields will be sent to the server as
  1103. // null. It is an error if a field in this list has a non-empty value.
  1104. // This may be used to include null fields in Patch requests.
  1105. NullFields []string `json:"-"`
  1106. }
  1107. func (s *StatusMessage) MarshalJSON() ([]byte, error) {
  1108. type NoMethod StatusMessage
  1109. raw := NoMethod(*s)
  1110. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1111. }
  1112. // UpdateActiveBreakpointRequest: Request to update an active
  1113. // breakpoint.
  1114. type UpdateActiveBreakpointRequest struct {
  1115. // Breakpoint: Updated breakpoint information.
  1116. // The field `id` must be set.
  1117. // The agent must echo all Breakpoint specification fields in the
  1118. // update.
  1119. Breakpoint *Breakpoint `json:"breakpoint,omitempty"`
  1120. // ForceSendFields is a list of field names (e.g. "Breakpoint") to
  1121. // unconditionally include in API requests. By default, fields with
  1122. // empty values are omitted from API requests. However, any non-pointer,
  1123. // non-interface field appearing in ForceSendFields will be sent to the
  1124. // server regardless of whether the field is empty or not. This may be
  1125. // used to include empty fields in Patch requests.
  1126. ForceSendFields []string `json:"-"`
  1127. // NullFields is a list of field names (e.g. "Breakpoint") to include in
  1128. // API requests with the JSON null value. By default, fields with empty
  1129. // values are omitted from API requests. However, any field with an
  1130. // empty value appearing in NullFields will be sent to the server as
  1131. // null. It is an error if a field in this list has a non-empty value.
  1132. // This may be used to include null fields in Patch requests.
  1133. NullFields []string `json:"-"`
  1134. }
  1135. func (s *UpdateActiveBreakpointRequest) MarshalJSON() ([]byte, error) {
  1136. type NoMethod UpdateActiveBreakpointRequest
  1137. raw := NoMethod(*s)
  1138. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1139. }
  1140. // UpdateActiveBreakpointResponse: Response for updating an active
  1141. // breakpoint.
  1142. // The message is defined to allow future extensions.
  1143. type UpdateActiveBreakpointResponse struct {
  1144. // ServerResponse contains the HTTP response code and headers from the
  1145. // server.
  1146. googleapi.ServerResponse `json:"-"`
  1147. }
  1148. // Variable: Represents a variable or an argument possibly of a compound
  1149. // object type.
  1150. // Note how the following variables are represented:
  1151. //
  1152. // 1) A simple variable:
  1153. //
  1154. // int x = 5
  1155. //
  1156. // { name: "x", value: "5", type: "int" } // Captured variable
  1157. //
  1158. // 2) A compound object:
  1159. //
  1160. // struct T {
  1161. // int m1;
  1162. // int m2;
  1163. // };
  1164. // T x = { 3, 7 };
  1165. //
  1166. // { // Captured variable
  1167. // name: "x",
  1168. // type: "T",
  1169. // members { name: "m1", value: "3", type: "int" },
  1170. // members { name: "m2", value: "7", type: "int" }
  1171. // }
  1172. //
  1173. // 3) A pointer where the pointee was captured:
  1174. //
  1175. // T x = { 3, 7 };
  1176. // T* p = &x;
  1177. //
  1178. // { // Captured variable
  1179. // name: "p",
  1180. // type: "T*",
  1181. // value: "0x00500500",
  1182. // members { name: "m1", value: "3", type: "int" },
  1183. // members { name: "m2", value: "7", type: "int" }
  1184. // }
  1185. //
  1186. // 4) A pointer where the pointee was not captured:
  1187. //
  1188. // T* p = new T;
  1189. //
  1190. // { // Captured variable
  1191. // name: "p",
  1192. // type: "T*",
  1193. // value: "0x00400400"
  1194. // status { is_error: true, description { format: "unavailable"
  1195. // } }
  1196. // }
  1197. //
  1198. // The status should describe the reason for the missing value,
  1199. // such as `<optimized out>`, `<inaccessible>`, `<pointers limit
  1200. // reached>`.
  1201. //
  1202. // Note that a null pointer should not have members.
  1203. //
  1204. // 5) An unnamed value:
  1205. //
  1206. // int* p = new int(7);
  1207. //
  1208. // { // Captured variable
  1209. // name: "p",
  1210. // value: "0x00500500",
  1211. // type: "int*",
  1212. // members { value: "7", type: "int" } }
  1213. //
  1214. // 6) An unnamed pointer where the pointee was not captured:
  1215. //
  1216. // int* p = new int(7);
  1217. // int** pp = &p;
  1218. //
  1219. // { // Captured variable
  1220. // name: "pp",
  1221. // value: "0x00500500",
  1222. // type: "int**",
  1223. // members {
  1224. // value: "0x00400400",
  1225. // type: "int*"
  1226. // status {
  1227. // is_error: true,
  1228. // description: { format: "unavailable" } }
  1229. // }
  1230. // }
  1231. // }
  1232. //
  1233. // To optimize computation, memory and network traffic, variables
  1234. // that
  1235. // repeat in the output multiple times can be stored once in a
  1236. // shared
  1237. // variable table and be referenced using the `var_table_index` field.
  1238. // The
  1239. // variables stored in the shared table are nameless and are
  1240. // essentially
  1241. // a partition of the complete variable. To reconstruct the
  1242. // complete
  1243. // variable, merge the referencing variable with the referenced
  1244. // variable.
  1245. //
  1246. // When using the shared variable table, the following variables:
  1247. //
  1248. // T x = { 3, 7 };
  1249. // T* p = &x;
  1250. // T& r = x;
  1251. //
  1252. // { name: "x", var_table_index: 3, type: "T" } // Captured
  1253. // variables
  1254. // { name: "p", value "0x00500500", type="T*", var_table_index: 3 }
  1255. // { name: "r", type="T&", var_table_index: 3 }
  1256. //
  1257. // { // Shared variable table entry #3:
  1258. // members { name: "m1", value: "3", type: "int" },
  1259. // members { name: "m2", value: "7", type: "int" }
  1260. // }
  1261. //
  1262. // Note that the pointer address is stored with the referencing
  1263. // variable
  1264. // and not with the referenced variable. This allows the referenced
  1265. // variable
  1266. // to be shared between pointers and references.
  1267. //
  1268. // The type field is optional. The debugger agent may or may not support
  1269. // it.
  1270. type Variable struct {
  1271. // Members: Members contained or pointed to by the variable.
  1272. Members []*Variable `json:"members,omitempty"`
  1273. // Name: Name of the variable, if any.
  1274. Name string `json:"name,omitempty"`
  1275. // Status: Status associated with the variable. This field will usually
  1276. // stay
  1277. // unset. A status of a single variable only applies to that variable
  1278. // or
  1279. // expression. The rest of breakpoint data still remains valid.
  1280. // Variables
  1281. // might be reported in error state even when breakpoint is not in
  1282. // final
  1283. // state.
  1284. //
  1285. // The message may refer to variable name with `refers_to` set
  1286. // to
  1287. // `VARIABLE_NAME`. Alternatively `refers_to` will be set to
  1288. // `VARIABLE_VALUE`.
  1289. // In either case variable value and members will be unset.
  1290. //
  1291. // Example of error message applied to name: `Invalid expression
  1292. // syntax`.
  1293. //
  1294. // Example of information message applied to value: `Not
  1295. // captured`.
  1296. //
  1297. // Examples of error message applied to value:
  1298. //
  1299. // * `Malformed string`,
  1300. // * `Field f not found in class C`
  1301. // * `Null pointer dereference`
  1302. Status *StatusMessage `json:"status,omitempty"`
  1303. // Type: Variable type (e.g. `MyClass`). If the variable is split
  1304. // with
  1305. // `var_table_index`, `type` goes next to `value`. The interpretation
  1306. // of
  1307. // a type is agent specific. It is recommended to include the dynamic
  1308. // type
  1309. // rather than a static type of an object.
  1310. Type string `json:"type,omitempty"`
  1311. // Value: Simple value of the variable.
  1312. Value string `json:"value,omitempty"`
  1313. // VarTableIndex: Reference to a variable in the shared variable table.
  1314. // More than
  1315. // one variable can reference the same variable in the table.
  1316. // The
  1317. // `var_table_index` field is an index into `variable_table` in
  1318. // Breakpoint.
  1319. VarTableIndex int64 `json:"varTableIndex,omitempty"`
  1320. // ForceSendFields is a list of field names (e.g. "Members") to
  1321. // unconditionally include in API requests. By default, fields with
  1322. // empty values are omitted from API requests. However, any non-pointer,
  1323. // non-interface field appearing in ForceSendFields will be sent to the
  1324. // server regardless of whether the field is empty or not. This may be
  1325. // used to include empty fields in Patch requests.
  1326. ForceSendFields []string `json:"-"`
  1327. // NullFields is a list of field names (e.g. "Members") to include in
  1328. // API requests with the JSON null value. By default, fields with empty
  1329. // values are omitted from API requests. However, any field with an
  1330. // empty value appearing in NullFields will be sent to the server as
  1331. // null. It is an error if a field in this list has a non-empty value.
  1332. // This may be used to include null fields in Patch requests.
  1333. NullFields []string `json:"-"`
  1334. }
  1335. func (s *Variable) MarshalJSON() ([]byte, error) {
  1336. type NoMethod Variable
  1337. raw := NoMethod(*s)
  1338. return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1339. }
  1340. // method id "clouddebugger.controller.debuggees.register":
  1341. type ControllerDebuggeesRegisterCall struct {
  1342. s *Service
  1343. registerdebuggeerequest *RegisterDebuggeeRequest
  1344. urlParams_ gensupport.URLParams
  1345. ctx_ context.Context
  1346. header_ http.Header
  1347. }
  1348. // Register: Registers the debuggee with the controller service.
  1349. //
  1350. // All agents attached to the same application must call this method
  1351. // with
  1352. // exactly the same request content to get back the same stable
  1353. // `debuggee_id`.
  1354. // Agents should call this method again whenever
  1355. // `google.rpc.Code.NOT_FOUND`
  1356. // is returned from any controller method.
  1357. //
  1358. // This protocol allows the controller service to disable debuggees,
  1359. // recover
  1360. // from data loss, or change the `debuggee_id` format. Agents must
  1361. // handle
  1362. // `debuggee_id` value changing upon re-registration.
  1363. func (r *ControllerDebuggeesService) Register(registerdebuggeerequest *RegisterDebuggeeRequest) *ControllerDebuggeesRegisterCall {
  1364. c := &ControllerDebuggeesRegisterCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1365. c.registerdebuggeerequest = registerdebuggeerequest
  1366. return c
  1367. }
  1368. // Fields allows partial responses to be retrieved. See
  1369. // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  1370. // for more information.
  1371. func (c *ControllerDebuggeesRegisterCall) Fields(s ...googleapi.Field) *ControllerDebuggeesRegisterCall {
  1372. c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1373. return c
  1374. }
  1375. // Context sets the context to be used in this call's Do method. Any
  1376. // pending HTTP request will be aborted if the provided context is
  1377. // canceled.
  1378. func (c *ControllerDebuggeesRegisterCall) Context(ctx context.Context) *ControllerDebuggeesRegisterCall {
  1379. c.ctx_ = ctx
  1380. return c
  1381. }
  1382. // Header returns an http.Header that can be modified by the caller to
  1383. // add HTTP headers to the request.
  1384. func (c *ControllerDebuggeesRegisterCall) Header() http.Header {
  1385. if c.header_ == nil {
  1386. c.header_ = make(http.Header)
  1387. }
  1388. return c.header_
  1389. }
  1390. func (c *ControllerDebuggeesRegisterCall) doRequest(alt string) (*http.Response, error) {
  1391. reqHeaders := make(http.Header)
  1392. for k, v := range c.header_ {
  1393. reqHeaders[k] = v
  1394. }
  1395. reqHeaders.Set("User-Agent", c.s.userAgent())
  1396. var body io.Reader = nil
  1397. body, err := googleapi.WithoutDataWrapper.JSONReader(c.registerdebuggeerequest)
  1398. if err != nil {
  1399. return nil, err
  1400. }
  1401. reqHeaders.Set("Content-Type", "application/json")
  1402. c.urlParams_.Set("alt", alt)
  1403. c.urlParams_.Set("prettyPrint", "false")
  1404. urls := googleapi.ResolveRelative(c.s.BasePath, "v2/controller/debuggees/register")
  1405. urls += "?" + c.urlParams_.Encode()
  1406. req, err := http.NewRequest("POST", urls, body)
  1407. if err != nil {
  1408. return nil, err
  1409. }
  1410. req.Header = reqHeaders
  1411. return gensupport.SendRequest(c.ctx_, c.s.client, req)
  1412. }
  1413. // Do executes the "clouddebugger.controller.debuggees.register" call.
  1414. // Exactly one of *RegisterDebuggeeResponse or error will be non-nil.
  1415. // Any non-2xx status code is an error. Response headers are in either
  1416. // *RegisterDebuggeeResponse.ServerResponse.Header or (if a response was
  1417. // returned at all) in error.(*googleapi.Error).Header. Use
  1418. // googleapi.IsNotModified to check whether the returned error was
  1419. // because http.StatusNotModified was returned.
  1420. func (c *ControllerDebuggeesRegisterCall) Do(opts ...googleapi.CallOption) (*RegisterDebuggeeResponse, error) {
  1421. gensupport.SetOptions(c.urlParams_, opts...)
  1422. res, err := c.doRequest("json")
  1423. if res != nil && res.StatusCode == http.StatusNotModified {
  1424. if res.Body != nil {
  1425. res.Body.Close()
  1426. }
  1427. return nil, &googleapi.Error{
  1428. Code: res.StatusCode,
  1429. Header: res.Header,
  1430. }
  1431. }
  1432. if err != nil {
  1433. return nil, err
  1434. }
  1435. defer googleapi.CloseBody(res)
  1436. if err := googleapi.CheckResponse(res); err != nil {
  1437. return nil, err
  1438. }
  1439. ret := &RegisterDebuggeeResponse{
  1440. ServerResponse: googleapi.ServerResponse{
  1441. Header: res.Header,
  1442. HTTPStatusCode: res.StatusCode,
  1443. },
  1444. }
  1445. target := &ret
  1446. if err := gensupport.DecodeResponse(target, res); err != nil {
  1447. return nil, err
  1448. }
  1449. return ret, nil
  1450. // {
  1451. // "description": "Registers the debuggee with the controller service.\n\nAll agents attached to the same application must call this method with\nexactly the same request content to get back the same stable `debuggee_id`.\nAgents should call this method again whenever `google.rpc.Code.NOT_FOUND`\nis returned from any controller method.\n\nThis protocol allows the controller service to disable debuggees, recover\nfrom data loss, or change the `debuggee_id` format. Agents must handle\n`debuggee_id` value changing upon re-registration.",
  1452. // "flatPath": "v2/controller/debuggees/register",
  1453. // "httpMethod": "POST",
  1454. // "id": "clouddebugger.controller.debuggees.register",
  1455. // "parameterOrder": [],
  1456. // "parameters": {},
  1457. // "path": "v2/controller/debuggees/register",
  1458. // "request": {
  1459. // "$ref": "RegisterDebuggeeRequest"
  1460. // },
  1461. // "response": {
  1462. // "$ref": "RegisterDebuggeeResponse"
  1463. // },
  1464. // "scopes": [
  1465. // "https://www.googleapis.com/auth/cloud-platform",
  1466. // "https://www.googleapis.com/auth/cloud_debugger"
  1467. // ]
  1468. // }
  1469. }
  1470. // method id "clouddebugger.controller.debuggees.breakpoints.list":
  1471. type ControllerDebuggeesBreakpointsListCall struct {
  1472. s *Service
  1473. debuggeeId string
  1474. urlParams_ gensupport.URLParams
  1475. ifNoneMatch_ string
  1476. ctx_ context.Context
  1477. header_ http.Header
  1478. }
  1479. // List: Returns the list of all active breakpoints for the
  1480. // debuggee.
  1481. //
  1482. // The breakpoint specification (`location`, `condition`, and
  1483. // `expressions`
  1484. // fields) is semantically immutable, although the field values
  1485. // may
  1486. // change. For example, an agent may update the location line number
  1487. // to reflect the actual line where the breakpoint was set, but
  1488. // this
  1489. // doesn't change the breakpoint semantics.
  1490. //
  1491. // This means that an agent does not need to check if a breakpoint has
  1492. // changed
  1493. // when it encounters the same breakpoint on a successive
  1494. // call.
  1495. // Moreover, an agent should remember the breakpoints that are
  1496. // completed
  1497. // until the controller removes them from the active list to
  1498. // avoid
  1499. // setting those breakpoints again.
  1500. func (r *ControllerDebuggeesBreakpointsService) List(debuggeeId string) *ControllerDebuggeesBreakpointsListCall {
  1501. c := &ControllerDebuggeesBreakpointsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1502. c.debuggeeId = debuggeeId
  1503. return c
  1504. }
  1505. // SuccessOnTimeout sets the optional parameter "successOnTimeout": If
  1506. // set to `true` (recommended), returns `google.rpc.Code.OK` status
  1507. // and
  1508. // sets the `wait_expired` response field to `true` when the
  1509. // server-selected
  1510. // timeout has expired.
  1511. //
  1512. // If set to `false` (deprecated), returns `google.rpc.Code.ABORTED`
  1513. // status
  1514. // when the server-selected timeout has expired.
  1515. func (c *ControllerDebuggeesBreakpointsListCall) SuccessOnTimeout(successOnTimeout bool) *ControllerDebuggeesBreakpointsListCall {
  1516. c.urlParams_.Set("successOnTimeout", fmt.Sprint(successOnTimeout))
  1517. return c
  1518. }
  1519. // WaitToken sets the optional parameter "waitToken": A token that, if
  1520. // specified, blocks the method call until the list
  1521. // of active breakpoints has changed, or a server-selected timeout
  1522. // has
  1523. // expired. The value should be set from the `next_wait_token` field
  1524. // in
  1525. // the last response. The initial value should be set to "init".
  1526. func (c *ControllerDebuggeesBreakpointsListCall) WaitToken(waitToken string) *ControllerDebuggeesBreakpointsListCall {
  1527. c.urlParams_.Set("waitToken", waitToken)
  1528. return c
  1529. }
  1530. // Fields allows partial responses to be retrieved. See
  1531. // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  1532. // for more information.
  1533. func (c *ControllerDebuggeesBreakpointsListCall) Fields(s ...googleapi.Field) *ControllerDebuggeesBreakpointsListCall {
  1534. c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1535. return c
  1536. }
  1537. // IfNoneMatch sets the optional parameter which makes the operation
  1538. // fail if the object's ETag matches the given value. This is useful for
  1539. // getting updates only after the object has changed since the last
  1540. // request. Use googleapi.IsNotModified to check whether the response
  1541. // error from Do is the result of In-None-Match.
  1542. func (c *ControllerDebuggeesBreakpointsListCall) IfNoneMatch(entityTag string) *ControllerDebuggeesBreakpointsListCall {
  1543. c.ifNoneMatch_ = entityTag
  1544. return c
  1545. }
  1546. // Context sets the context to be used in this call's Do method. Any
  1547. // pending HTTP request will be aborted if the provided context is
  1548. // canceled.
  1549. func (c *ControllerDebuggeesBreakpointsListCall) Context(ctx context.Context) *ControllerDebuggeesBreakpointsListCall {
  1550. c.ctx_ = ctx
  1551. return c
  1552. }
  1553. // Header returns an http.Header that can be modified by the caller to
  1554. // add HTTP headers to the request.
  1555. func (c *ControllerDebuggeesBreakpointsListCall) Header() http.Header {
  1556. if c.header_ == nil {
  1557. c.header_ = make(http.Header)
  1558. }
  1559. return c.header_
  1560. }
  1561. func (c *ControllerDebuggeesBreakpointsListCall) doRequest(alt string) (*http.Response, error) {
  1562. reqHeaders := make(http.Header)
  1563. for k, v := range c.header_ {
  1564. reqHeaders[k] = v
  1565. }
  1566. reqHeaders.Set("User-Agent", c.s.userAgent())
  1567. if c.ifNoneMatch_ != "" {
  1568. reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  1569. }
  1570. var body io.Reader = nil
  1571. c.urlParams_.Set("alt", alt)
  1572. c.urlParams_.Set("prettyPrint", "false")
  1573. urls := googleapi.ResolveRelative(c.s.BasePath, "v2/controller/debuggees/{debuggeeId}/breakpoints")
  1574. urls += "?" + c.urlParams_.Encode()
  1575. req, err := http.NewRequest("GET", urls, body)
  1576. if err != nil {
  1577. return nil, err
  1578. }
  1579. req.Header = reqHeaders
  1580. googleapi.Expand(req.URL, map[string]string{
  1581. "debuggeeId": c.debuggeeId,
  1582. })
  1583. return gensupport.SendRequest(c.ctx_, c.s.client, req)
  1584. }
  1585. // Do executes the "clouddebugger.controller.debuggees.breakpoints.list" call.
  1586. // Exactly one of *ListActiveBreakpointsResponse or error will be
  1587. // non-nil. Any non-2xx status code is an error. Response headers are in
  1588. // either *ListActiveBreakpointsResponse.ServerResponse.Header or (if a
  1589. // response was returned at all) in error.(*googleapi.Error).Header. Use
  1590. // googleapi.IsNotModified to check whether the returned error was
  1591. // because http.StatusNotModified was returned.
  1592. func (c *ControllerDebuggeesBreakpointsListCall) Do(opts ...googleapi.CallOption) (*ListActiveBreakpointsResponse, error) {
  1593. gensupport.SetOptions(c.urlParams_, opts...)
  1594. res, err := c.doRequest("json")
  1595. if res != nil && res.StatusCode == http.StatusNotModified {
  1596. if res.Body != nil {
  1597. res.Body.Close()
  1598. }
  1599. return nil, &googleapi.Error{
  1600. Code: res.StatusCode,
  1601. Header: res.Header,
  1602. }
  1603. }
  1604. if err != nil {
  1605. return nil, err
  1606. }
  1607. defer googleapi.CloseBody(res)
  1608. if err := googleapi.CheckResponse(res); err != nil {
  1609. return nil, err
  1610. }
  1611. ret := &ListActiveBreakpointsResponse{
  1612. ServerResponse: googleapi.ServerResponse{
  1613. Header: res.Header,
  1614. HTTPStatusCode: res.StatusCode,
  1615. },
  1616. }
  1617. target := &ret
  1618. if err := gensupport.DecodeResponse(target, res); err != nil {
  1619. return nil, err
  1620. }
  1621. return ret, nil
  1622. // {
  1623. // "description": "Returns the list of all active breakpoints for the debuggee.\n\nThe breakpoint specification (`location`, `condition`, and `expressions`\nfields) is semantically immutable, although the field values may\nchange. For example, an agent may update the location line number\nto reflect the actual line where the breakpoint was set, but this\ndoesn't change the breakpoint semantics.\n\nThis means that an agent does not need to check if a breakpoint has changed\nwhen it encounters the same breakpoint on a successive call.\nMoreover, an agent should remember the breakpoints that are completed\nuntil the controller removes them from the active list to avoid\nsetting those breakpoints again.",
  1624. // "flatPath": "v2/controller/debuggees/{debuggeeId}/breakpoints",
  1625. // "httpMethod": "GET",
  1626. // "id": "clouddebugger.controller.debuggees.breakpoints.list",
  1627. // "parameterOrder": [
  1628. // "debuggeeId"
  1629. // ],
  1630. // "parameters": {
  1631. // "debuggeeId": {
  1632. // "description": "Identifies the debuggee.",
  1633. // "location": "path",
  1634. // "required": true,
  1635. // "type": "string"
  1636. // },
  1637. // "successOnTimeout": {
  1638. // "description": "If set to `true` (recommended), returns `google.rpc.Code.OK` status and\nsets the `wait_expired` response field to `true` when the server-selected\ntimeout has expired.\n\nIf set to `false` (deprecated), returns `google.rpc.Code.ABORTED` status\nwhen the server-selected timeout has expired.",
  1639. // "location": "query",
  1640. // "type": "boolean"
  1641. // },
  1642. // "waitToken": {
  1643. // "description": "A token that, if specified, blocks the method call until the list\nof active breakpoints has changed, or a server-selected timeout has\nexpired. The value should be set from the `next_wait_token` field in\nthe last response. The initial value should be set to `\"init\"`.",
  1644. // "location": "query",
  1645. // "type": "string"
  1646. // }
  1647. // },
  1648. // "path": "v2/controller/debuggees/{debuggeeId}/breakpoints",
  1649. // "response": {
  1650. // "$ref": "ListActiveBreakpointsResponse"
  1651. // },
  1652. // "scopes": [
  1653. // "https://www.googleapis.com/auth/cloud-platform",
  1654. // "https://www.googleapis.com/auth/cloud_debugger"
  1655. // ]
  1656. // }
  1657. }
  1658. // method id "clouddebugger.controller.debuggees.breakpoints.update":
  1659. type ControllerDebuggeesBreakpointsUpdateCall struct {
  1660. s *Service
  1661. debuggeeId string
  1662. id string
  1663. updateactivebreakpointrequest *UpdateActiveBreakpointRequest
  1664. urlParams_ gensupport.URLParams
  1665. ctx_ context.Context
  1666. header_ http.Header
  1667. }
  1668. // Update: Updates the breakpoint state or mutable fields.
  1669. // The entire Breakpoint message must be sent back to the controller
  1670. // service.
  1671. //
  1672. // Updates to active breakpoint fields are only allowed if the new
  1673. // value
  1674. // does not change the breakpoint specification. Updates to the
  1675. // `location`,
  1676. // `condition` and `expressions` fields should not alter the
  1677. // breakpoint
  1678. // semantics. These may only make changes such as canonicalizing a
  1679. // value
  1680. // or snapping the location to the correct line of code.
  1681. func (r *ControllerDebuggeesBreakpointsService) Update(debuggeeId string, id string, updateactivebreakpointrequest *UpdateActiveBreakpointRequest) *ControllerDebuggeesBreakpointsUpdateCall {
  1682. c := &ControllerDebuggeesBreakpointsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1683. c.debuggeeId = debuggeeId
  1684. c.id = id
  1685. c.updateactivebreakpointrequest = updateactivebreakpointrequest
  1686. return c
  1687. }
  1688. // Fields allows partial responses to be retrieved. See
  1689. // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  1690. // for more information.
  1691. func (c *ControllerDebuggeesBreakpointsUpdateCall) Fields(s ...googleapi.Field) *ControllerDebuggeesBreakpointsUpdateCall {
  1692. c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1693. return c
  1694. }
  1695. // Context sets the context to be used in this call's Do method. Any
  1696. // pending HTTP request will be aborted if the provided context is
  1697. // canceled.
  1698. func (c *ControllerDebuggeesBreakpointsUpdateCall) Context(ctx context.Context) *ControllerDebuggeesBreakpointsUpdateCall {
  1699. c.ctx_ = ctx
  1700. return c
  1701. }
  1702. // Header returns an http.Header that can be modified by the caller to
  1703. // add HTTP headers to the request.
  1704. func (c *ControllerDebuggeesBreakpointsUpdateCall) Header() http.Header {
  1705. if c.header_ == nil {
  1706. c.header_ = make(http.Header)
  1707. }
  1708. return c.header_
  1709. }
  1710. func (c *ControllerDebuggeesBreakpointsUpdateCall) doRequest(alt string) (*http.Response, error) {
  1711. reqHeaders := make(http.Header)
  1712. for k, v := range c.header_ {
  1713. reqHeaders[k] = v
  1714. }
  1715. reqHeaders.Set("User-Agent", c.s.userAgent())
  1716. var body io.Reader = nil
  1717. body, err := googleapi.WithoutDataWrapper.JSONReader(c.updateactivebreakpointrequest)
  1718. if err != nil {
  1719. return nil, err
  1720. }
  1721. reqHeaders.Set("Content-Type", "application/json")
  1722. c.urlParams_.Set("alt", alt)
  1723. c.urlParams_.Set("prettyPrint", "false")
  1724. urls := googleapi.ResolveRelative(c.s.BasePath, "v2/controller/debuggees/{debuggeeId}/breakpoints/{id}")
  1725. urls += "?" + c.urlParams_.Encode()
  1726. req, err := http.NewRequest("PUT", urls, body)
  1727. if err != nil {
  1728. return nil, err
  1729. }
  1730. req.Header = reqHeaders
  1731. googleapi.Expand(req.URL, map[string]string{
  1732. "debuggeeId": c.debuggeeId,
  1733. "id": c.id,
  1734. })
  1735. return gensupport.SendRequest(c.ctx_, c.s.client, req)
  1736. }
  1737. // Do executes the "clouddebugger.controller.debuggees.breakpoints.update" call.
  1738. // Exactly one of *UpdateActiveBreakpointResponse or error will be
  1739. // non-nil. Any non-2xx status code is an error. Response headers are in
  1740. // either *UpdateActiveBreakpointResponse.ServerResponse.Header or (if a
  1741. // response was returned at all) in error.(*googleapi.Error).Header. Use
  1742. // googleapi.IsNotModified to check whether the returned error was
  1743. // because http.StatusNotModified was returned.
  1744. func (c *ControllerDebuggeesBreakpointsUpdateCall) Do(opts ...googleapi.CallOption) (*UpdateActiveBreakpointResponse, error) {
  1745. gensupport.SetOptions(c.urlParams_, opts...)
  1746. res, err := c.doRequest("json")
  1747. if res != nil && res.StatusCode == http.StatusNotModified {
  1748. if res.Body != nil {
  1749. res.Body.Close()
  1750. }
  1751. return nil, &googleapi.Error{
  1752. Code: res.StatusCode,
  1753. Header: res.Header,
  1754. }
  1755. }
  1756. if err != nil {
  1757. return nil, err
  1758. }
  1759. defer googleapi.CloseBody(res)
  1760. if err := googleapi.CheckResponse(res); err != nil {
  1761. return nil, err
  1762. }
  1763. ret := &UpdateActiveBreakpointResponse{
  1764. ServerResponse: googleapi.ServerResponse{
  1765. Header: res.Header,
  1766. HTTPStatusCode: res.StatusCode,
  1767. },
  1768. }
  1769. target := &ret
  1770. if err := gensupport.DecodeResponse(target, res); err != nil {
  1771. return nil, err
  1772. }
  1773. return ret, nil
  1774. // {
  1775. // "description": "Updates the breakpoint state or mutable fields.\nThe entire Breakpoint message must be sent back to the controller service.\n\nUpdates to active breakpoint fields are only allowed if the new value\ndoes not change the breakpoint specification. Updates to the `location`,\n`condition` and `expressions` fields should not alter the breakpoint\nsemantics. These may only make changes such as canonicalizing a value\nor snapping the location to the correct line of code.",
  1776. // "flatPath": "v2/controller/debuggees/{debuggeeId}/breakpoints/{id}",
  1777. // "httpMethod": "PUT",
  1778. // "id": "clouddebugger.controller.debuggees.breakpoints.update",
  1779. // "parameterOrder": [
  1780. // "debuggeeId",
  1781. // "id"
  1782. // ],
  1783. // "parameters": {
  1784. // "debuggeeId": {
  1785. // "description": "Identifies the debuggee being debugged.",
  1786. // "location": "path",
  1787. // "required": true,
  1788. // "type": "string"
  1789. // },
  1790. // "id": {
  1791. // "description": "Breakpoint identifier, unique in the scope of the debuggee.",
  1792. // "location": "path",
  1793. // "required": true,
  1794. // "type": "string"
  1795. // }
  1796. // },
  1797. // "path": "v2/controller/debuggees/{debuggeeId}/breakpoints/{id}",
  1798. // "request": {
  1799. // "$ref": "UpdateActiveBreakpointRequest"
  1800. // },
  1801. // "response": {
  1802. // "$ref": "UpdateActiveBreakpointResponse"
  1803. // },
  1804. // "scopes": [
  1805. // "https://www.googleapis.com/auth/cloud-platform",
  1806. // "https://www.googleapis.com/auth/cloud_debugger"
  1807. // ]
  1808. // }
  1809. }
  1810. // method id "clouddebugger.debugger.debuggees.list":
  1811. type DebuggerDebuggeesListCall struct {
  1812. s *Service
  1813. urlParams_ gensupport.URLParams
  1814. ifNoneMatch_ string
  1815. ctx_ context.Context
  1816. header_ http.Header
  1817. }
  1818. // List: Lists all the debuggees that the user has access to.
  1819. func (r *DebuggerDebuggeesService) List() *DebuggerDebuggeesListCall {
  1820. c := &DebuggerDebuggeesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1821. return c
  1822. }
  1823. // ClientVersion sets the optional parameter "clientVersion": The client
  1824. // version making the call.
  1825. // Schema: `domain/type/version` (e.g., `google.com/intellij/v1`).
  1826. func (c *DebuggerDebuggeesListCall) ClientVersion(clientVersion string) *DebuggerDebuggeesListCall {
  1827. c.urlParams_.Set("clientVersion", clientVersion)
  1828. return c
  1829. }
  1830. // IncludeInactive sets the optional parameter "includeInactive": When
  1831. // set to `true`, the result includes all debuggees. Otherwise,
  1832. // the
  1833. // result includes only debuggees that are active.
  1834. func (c *DebuggerDebuggeesListCall) IncludeInactive(includeInactive bool) *DebuggerDebuggeesListCall {
  1835. c.urlParams_.Set("includeInactive", fmt.Sprint(includeInactive))
  1836. return c
  1837. }
  1838. // Project sets the optional parameter "project": Project number of a
  1839. // Google Cloud project whose debuggees to list.
  1840. func (c *DebuggerDebuggeesListCall) Project(project string) *DebuggerDebuggeesListCall {
  1841. c.urlParams_.Set("project", project)
  1842. return c
  1843. }
  1844. // Fields allows partial responses to be retrieved. See
  1845. // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  1846. // for more information.
  1847. func (c *DebuggerDebuggeesListCall) Fields(s ...googleapi.Field) *DebuggerDebuggeesListCall {
  1848. c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1849. return c
  1850. }
  1851. // IfNoneMatch sets the optional parameter which makes the operation
  1852. // fail if the object's ETag matches the given value. This is useful for
  1853. // getting updates only after the object has changed since the last
  1854. // request. Use googleapi.IsNotModified to check whether the response
  1855. // error from Do is the result of In-None-Match.
  1856. func (c *DebuggerDebuggeesListCall) IfNoneMatch(entityTag string) *DebuggerDebuggeesListCall {
  1857. c.ifNoneMatch_ = entityTag
  1858. return c
  1859. }
  1860. // Context sets the context to be used in this call's Do method. Any
  1861. // pending HTTP request will be aborted if the provided context is
  1862. // canceled.
  1863. func (c *DebuggerDebuggeesListCall) Context(ctx context.Context) *DebuggerDebuggeesListCall {
  1864. c.ctx_ = ctx
  1865. return c
  1866. }
  1867. // Header returns an http.Header that can be modified by the caller to
  1868. // add HTTP headers to the request.
  1869. func (c *DebuggerDebuggeesListCall) Header() http.Header {
  1870. if c.header_ == nil {
  1871. c.header_ = make(http.Header)
  1872. }
  1873. return c.header_
  1874. }
  1875. func (c *DebuggerDebuggeesListCall) doRequest(alt string) (*http.Response, error) {
  1876. reqHeaders := make(http.Header)
  1877. for k, v := range c.header_ {
  1878. reqHeaders[k] = v
  1879. }
  1880. reqHeaders.Set("User-Agent", c.s.userAgent())
  1881. if c.ifNoneMatch_ != "" {
  1882. reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  1883. }
  1884. var body io.Reader = nil
  1885. c.urlParams_.Set("alt", alt)
  1886. c.urlParams_.Set("prettyPrint", "false")
  1887. urls := googleapi.ResolveRelative(c.s.BasePath, "v2/debugger/debuggees")
  1888. urls += "?" + c.urlParams_.Encode()
  1889. req, err := http.NewRequest("GET", urls, body)
  1890. if err != nil {
  1891. return nil, err
  1892. }
  1893. req.Header = reqHeaders
  1894. return gensupport.SendRequest(c.ctx_, c.s.client, req)
  1895. }
  1896. // Do executes the "clouddebugger.debugger.debuggees.list" call.
  1897. // Exactly one of *ListDebuggeesResponse or error will be non-nil. Any
  1898. // non-2xx status code is an error. Response headers are in either
  1899. // *ListDebuggeesResponse.ServerResponse.Header or (if a response was
  1900. // returned at all) in error.(*googleapi.Error).Header. Use
  1901. // googleapi.IsNotModified to check whether the returned error was
  1902. // because http.StatusNotModified was returned.
  1903. func (c *DebuggerDebuggeesListCall) Do(opts ...googleapi.CallOption) (*ListDebuggeesResponse, error) {
  1904. gensupport.SetOptions(c.urlParams_, opts...)
  1905. res, err := c.doRequest("json")
  1906. if res != nil && res.StatusCode == http.StatusNotModified {
  1907. if res.Body != nil {
  1908. res.Body.Close()
  1909. }
  1910. return nil, &googleapi.Error{
  1911. Code: res.StatusCode,
  1912. Header: res.Header,
  1913. }
  1914. }
  1915. if err != nil {
  1916. return nil, err
  1917. }
  1918. defer googleapi.CloseBody(res)
  1919. if err := googleapi.CheckResponse(res); err != nil {
  1920. return nil, err
  1921. }
  1922. ret := &ListDebuggeesResponse{
  1923. ServerResponse: googleapi.ServerResponse{
  1924. Header: res.Header,
  1925. HTTPStatusCode: res.StatusCode,
  1926. },
  1927. }
  1928. target := &ret
  1929. if err := gensupport.DecodeResponse(target, res); err != nil {
  1930. return nil, err
  1931. }
  1932. return ret, nil
  1933. // {
  1934. // "description": "Lists all the debuggees that the user has access to.",
  1935. // "flatPath": "v2/debugger/debuggees",
  1936. // "httpMethod": "GET",
  1937. // "id": "clouddebugger.debugger.debuggees.list",
  1938. // "parameterOrder": [],
  1939. // "parameters": {
  1940. // "clientVersion": {
  1941. // "description": "The client version making the call.\nSchema: `domain/type/version` (e.g., `google.com/intellij/v1`).",
  1942. // "location": "query",
  1943. // "type": "string"
  1944. // },
  1945. // "includeInactive": {
  1946. // "description": "When set to `true`, the result includes all debuggees. Otherwise, the\nresult includes only debuggees that are active.",
  1947. // "location": "query",
  1948. // "type": "boolean"
  1949. // },
  1950. // "project": {
  1951. // "description": "Project number of a Google Cloud project whose debuggees to list.",
  1952. // "location": "query",
  1953. // "type": "string"
  1954. // }
  1955. // },
  1956. // "path": "v2/debugger/debuggees",
  1957. // "response": {
  1958. // "$ref": "ListDebuggeesResponse"
  1959. // },
  1960. // "scopes": [
  1961. // "https://www.googleapis.com/auth/cloud-platform",
  1962. // "https://www.googleapis.com/auth/cloud_debugger"
  1963. // ]
  1964. // }
  1965. }
  1966. // method id "clouddebugger.debugger.debuggees.breakpoints.delete":
  1967. type DebuggerDebuggeesBreakpointsDeleteCall struct {
  1968. s *Service
  1969. debuggeeId string
  1970. breakpointId string
  1971. urlParams_ gensupport.URLParams
  1972. ctx_ context.Context
  1973. header_ http.Header
  1974. }
  1975. // Delete: Deletes the breakpoint from the debuggee.
  1976. func (r *DebuggerDebuggeesBreakpointsService) Delete(debuggeeId string, breakpointId string) *DebuggerDebuggeesBreakpointsDeleteCall {
  1977. c := &DebuggerDebuggeesBreakpointsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1978. c.debuggeeId = debuggeeId
  1979. c.breakpointId = breakpointId
  1980. return c
  1981. }
  1982. // ClientVersion sets the optional parameter "clientVersion": The client
  1983. // version making the call.
  1984. // Schema: `domain/type/version` (e.g., `google.com/intellij/v1`).
  1985. func (c *DebuggerDebuggeesBreakpointsDeleteCall) ClientVersion(clientVersion string) *DebuggerDebuggeesBreakpointsDeleteCall {
  1986. c.urlParams_.Set("clientVersion", clientVersion)
  1987. return c
  1988. }
  1989. // Fields allows partial responses to be retrieved. See
  1990. // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  1991. // for more information.
  1992. func (c *DebuggerDebuggeesBreakpointsDeleteCall) Fields(s ...googleapi.Field) *DebuggerDebuggeesBreakpointsDeleteCall {
  1993. c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1994. return c
  1995. }
  1996. // Context sets the context to be used in this call's Do method. Any
  1997. // pending HTTP request will be aborted if the provided context is
  1998. // canceled.
  1999. func (c *DebuggerDebuggeesBreakpointsDeleteCall) Context(ctx context.Context) *DebuggerDebuggeesBreakpointsDeleteCall {
  2000. c.ctx_ = ctx
  2001. return c
  2002. }
  2003. // Header returns an http.Header that can be modified by the caller to
  2004. // add HTTP headers to the request.
  2005. func (c *DebuggerDebuggeesBreakpointsDeleteCall) Header() http.Header {
  2006. if c.header_ == nil {
  2007. c.header_ = make(http.Header)
  2008. }
  2009. return c.header_
  2010. }
  2011. func (c *DebuggerDebuggeesBreakpointsDeleteCall) doRequest(alt string) (*http.Response, error) {
  2012. reqHeaders := make(http.Header)
  2013. for k, v := range c.header_ {
  2014. reqHeaders[k] = v
  2015. }
  2016. reqHeaders.Set("User-Agent", c.s.userAgent())
  2017. var body io.Reader = nil
  2018. c.urlParams_.Set("alt", alt)
  2019. c.urlParams_.Set("prettyPrint", "false")
  2020. urls := googleapi.ResolveRelative(c.s.BasePath, "v2/debugger/debuggees/{debuggeeId}/breakpoints/{breakpointId}")
  2021. urls += "?" + c.urlParams_.Encode()
  2022. req, err := http.NewRequest("DELETE", urls, body)
  2023. if err != nil {
  2024. return nil, err
  2025. }
  2026. req.Header = reqHeaders
  2027. googleapi.Expand(req.URL, map[string]string{
  2028. "debuggeeId": c.debuggeeId,
  2029. "breakpointId": c.breakpointId,
  2030. })
  2031. return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2032. }
  2033. // Do executes the "clouddebugger.debugger.debuggees.breakpoints.delete" call.
  2034. // Exactly one of *Empty or error will be non-nil. Any non-2xx status
  2035. // code is an error. Response headers are in either
  2036. // *Empty.ServerResponse.Header or (if a response was returned at all)
  2037. // in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  2038. // check whether the returned error was because http.StatusNotModified
  2039. // was returned.
  2040. func (c *DebuggerDebuggeesBreakpointsDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, error) {
  2041. gensupport.SetOptions(c.urlParams_, opts...)
  2042. res, err := c.doRequest("json")
  2043. if res != nil && res.StatusCode == http.StatusNotModified {
  2044. if res.Body != nil {
  2045. res.Body.Close()
  2046. }
  2047. return nil, &googleapi.Error{
  2048. Code: res.StatusCode,
  2049. Header: res.Header,
  2050. }
  2051. }
  2052. if err != nil {
  2053. return nil, err
  2054. }
  2055. defer googleapi.CloseBody(res)
  2056. if err := googleapi.CheckResponse(res); err != nil {
  2057. return nil, err
  2058. }
  2059. ret := &Empty{
  2060. ServerResponse: googleapi.ServerResponse{
  2061. Header: res.Header,
  2062. HTTPStatusCode: res.StatusCode,
  2063. },
  2064. }
  2065. target := &ret
  2066. if err := gensupport.DecodeResponse(target, res); err != nil {
  2067. return nil, err
  2068. }
  2069. return ret, nil
  2070. // {
  2071. // "description": "Deletes the breakpoint from the debuggee.",
  2072. // "flatPath": "v2/debugger/debuggees/{debuggeeId}/breakpoints/{breakpointId}",
  2073. // "httpMethod": "DELETE",
  2074. // "id": "clouddebugger.debugger.debuggees.breakpoints.delete",
  2075. // "parameterOrder": [
  2076. // "debuggeeId",
  2077. // "breakpointId"
  2078. // ],
  2079. // "parameters": {
  2080. // "breakpointId": {
  2081. // "description": "ID of the breakpoint to delete.",
  2082. // "location": "path",
  2083. // "required": true,
  2084. // "type": "string"
  2085. // },
  2086. // "clientVersion": {
  2087. // "description": "The client version making the call.\nSchema: `domain/type/version` (e.g., `google.com/intellij/v1`).",
  2088. // "location": "query",
  2089. // "type": "string"
  2090. // },
  2091. // "debuggeeId": {
  2092. // "description": "ID of the debuggee whose breakpoint to delete.",
  2093. // "location": "path",
  2094. // "required": true,
  2095. // "type": "string"
  2096. // }
  2097. // },
  2098. // "path": "v2/debugger/debuggees/{debuggeeId}/breakpoints/{breakpointId}",
  2099. // "response": {
  2100. // "$ref": "Empty"
  2101. // },
  2102. // "scopes": [
  2103. // "https://www.googleapis.com/auth/cloud-platform",
  2104. // "https://www.googleapis.com/auth/cloud_debugger"
  2105. // ]
  2106. // }
  2107. }
  2108. // method id "clouddebugger.debugger.debuggees.breakpoints.get":
  2109. type DebuggerDebuggeesBreakpointsGetCall struct {
  2110. s *Service
  2111. debuggeeId string
  2112. breakpointId string
  2113. urlParams_ gensupport.URLParams
  2114. ifNoneMatch_ string
  2115. ctx_ context.Context
  2116. header_ http.Header
  2117. }
  2118. // Get: Gets breakpoint information.
  2119. func (r *DebuggerDebuggeesBreakpointsService) Get(debuggeeId string, breakpointId string) *DebuggerDebuggeesBreakpointsGetCall {
  2120. c := &DebuggerDebuggeesBreakpointsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2121. c.debuggeeId = debuggeeId
  2122. c.breakpointId = breakpointId
  2123. return c
  2124. }
  2125. // ClientVersion sets the optional parameter "clientVersion": The client
  2126. // version making the call.
  2127. // Schema: `domain/type/version` (e.g., `google.com/intellij/v1`).
  2128. func (c *DebuggerDebuggeesBreakpointsGetCall) ClientVersion(clientVersion string) *DebuggerDebuggeesBreakpointsGetCall {
  2129. c.urlParams_.Set("clientVersion", clientVersion)
  2130. return c
  2131. }
  2132. // Fields allows partial responses to be retrieved. See
  2133. // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  2134. // for more information.
  2135. func (c *DebuggerDebuggeesBreakpointsGetCall) Fields(s ...googleapi.Field) *DebuggerDebuggeesBreakpointsGetCall {
  2136. c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2137. return c
  2138. }
  2139. // IfNoneMatch sets the optional parameter which makes the operation
  2140. // fail if the object's ETag matches the given value. This is useful for
  2141. // getting updates only after the object has changed since the last
  2142. // request. Use googleapi.IsNotModified to check whether the response
  2143. // error from Do is the result of In-None-Match.
  2144. func (c *DebuggerDebuggeesBreakpointsGetCall) IfNoneMatch(entityTag string) *DebuggerDebuggeesBreakpointsGetCall {
  2145. c.ifNoneMatch_ = entityTag
  2146. return c
  2147. }
  2148. // Context sets the context to be used in this call's Do method. Any
  2149. // pending HTTP request will be aborted if the provided context is
  2150. // canceled.
  2151. func (c *DebuggerDebuggeesBreakpointsGetCall) Context(ctx context.Context) *DebuggerDebuggeesBreakpointsGetCall {
  2152. c.ctx_ = ctx
  2153. return c
  2154. }
  2155. // Header returns an http.Header that can be modified by the caller to
  2156. // add HTTP headers to the request.
  2157. func (c *DebuggerDebuggeesBreakpointsGetCall) Header() http.Header {
  2158. if c.header_ == nil {
  2159. c.header_ = make(http.Header)
  2160. }
  2161. return c.header_
  2162. }
  2163. func (c *DebuggerDebuggeesBreakpointsGetCall) doRequest(alt string) (*http.Response, error) {
  2164. reqHeaders := make(http.Header)
  2165. for k, v := range c.header_ {
  2166. reqHeaders[k] = v
  2167. }
  2168. reqHeaders.Set("User-Agent", c.s.userAgent())
  2169. if c.ifNoneMatch_ != "" {
  2170. reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2171. }
  2172. var body io.Reader = nil
  2173. c.urlParams_.Set("alt", alt)
  2174. c.urlParams_.Set("prettyPrint", "false")
  2175. urls := googleapi.ResolveRelative(c.s.BasePath, "v2/debugger/debuggees/{debuggeeId}/breakpoints/{breakpointId}")
  2176. urls += "?" + c.urlParams_.Encode()
  2177. req, err := http.NewRequest("GET", urls, body)
  2178. if err != nil {
  2179. return nil, err
  2180. }
  2181. req.Header = reqHeaders
  2182. googleapi.Expand(req.URL, map[string]string{
  2183. "debuggeeId": c.debuggeeId,
  2184. "breakpointId": c.breakpointId,
  2185. })
  2186. return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2187. }
  2188. // Do executes the "clouddebugger.debugger.debuggees.breakpoints.get" call.
  2189. // Exactly one of *GetBreakpointResponse or error will be non-nil. Any
  2190. // non-2xx status code is an error. Response headers are in either
  2191. // *GetBreakpointResponse.ServerResponse.Header or (if a response was
  2192. // returned at all) in error.(*googleapi.Error).Header. Use
  2193. // googleapi.IsNotModified to check whether the returned error was
  2194. // because http.StatusNotModified was returned.
  2195. func (c *DebuggerDebuggeesBreakpointsGetCall) Do(opts ...googleapi.CallOption) (*GetBreakpointResponse, error) {
  2196. gensupport.SetOptions(c.urlParams_, opts...)
  2197. res, err := c.doRequest("json")
  2198. if res != nil && res.StatusCode == http.StatusNotModified {
  2199. if res.Body != nil {
  2200. res.Body.Close()
  2201. }
  2202. return nil, &googleapi.Error{
  2203. Code: res.StatusCode,
  2204. Header: res.Header,
  2205. }
  2206. }
  2207. if err != nil {
  2208. return nil, err
  2209. }
  2210. defer googleapi.CloseBody(res)
  2211. if err := googleapi.CheckResponse(res); err != nil {
  2212. return nil, err
  2213. }
  2214. ret := &GetBreakpointResponse{
  2215. ServerResponse: googleapi.ServerResponse{
  2216. Header: res.Header,
  2217. HTTPStatusCode: res.StatusCode,
  2218. },
  2219. }
  2220. target := &ret
  2221. if err := gensupport.DecodeResponse(target, res); err != nil {
  2222. return nil, err
  2223. }
  2224. return ret, nil
  2225. // {
  2226. // "description": "Gets breakpoint information.",
  2227. // "flatPath": "v2/debugger/debuggees/{debuggeeId}/breakpoints/{breakpointId}",
  2228. // "httpMethod": "GET",
  2229. // "id": "clouddebugger.debugger.debuggees.breakpoints.get",
  2230. // "parameterOrder": [
  2231. // "debuggeeId",
  2232. // "breakpointId"
  2233. // ],
  2234. // "parameters": {
  2235. // "breakpointId": {
  2236. // "description": "ID of the breakpoint to get.",
  2237. // "location": "path",
  2238. // "required": true,
  2239. // "type": "string"
  2240. // },
  2241. // "clientVersion": {
  2242. // "description": "The client version making the call.\nSchema: `domain/type/version` (e.g., `google.com/intellij/v1`).",
  2243. // "location": "query",
  2244. // "type": "string"
  2245. // },
  2246. // "debuggeeId": {
  2247. // "description": "ID of the debuggee whose breakpoint to get.",
  2248. // "location": "path",
  2249. // "required": true,
  2250. // "type": "string"
  2251. // }
  2252. // },
  2253. // "path": "v2/debugger/debuggees/{debuggeeId}/breakpoints/{breakpointId}",
  2254. // "response": {
  2255. // "$ref": "GetBreakpointResponse"
  2256. // },
  2257. // "scopes": [
  2258. // "https://www.googleapis.com/auth/cloud-platform",
  2259. // "https://www.googleapis.com/auth/cloud_debugger"
  2260. // ]
  2261. // }
  2262. }
  2263. // method id "clouddebugger.debugger.debuggees.breakpoints.list":
  2264. type DebuggerDebuggeesBreakpointsListCall struct {
  2265. s *Service
  2266. debuggeeId string
  2267. urlParams_ gensupport.URLParams
  2268. ifNoneMatch_ string
  2269. ctx_ context.Context
  2270. header_ http.Header
  2271. }
  2272. // List: Lists all breakpoints for the debuggee.
  2273. func (r *DebuggerDebuggeesBreakpointsService) List(debuggeeId string) *DebuggerDebuggeesBreakpointsListCall {
  2274. c := &DebuggerDebuggeesBreakpointsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2275. c.debuggeeId = debuggeeId
  2276. return c
  2277. }
  2278. // ActionValue sets the optional parameter "action.value": Only
  2279. // breakpoints with the specified action will pass the filter.
  2280. //
  2281. // Possible values:
  2282. // "CAPTURE"
  2283. // "LOG"
  2284. func (c *DebuggerDebuggeesBreakpointsListCall) ActionValue(actionValue string) *DebuggerDebuggeesBreakpointsListCall {
  2285. c.urlParams_.Set("action.value", actionValue)
  2286. return c
  2287. }
  2288. // ClientVersion sets the optional parameter "clientVersion": The client
  2289. // version making the call.
  2290. // Schema: `domain/type/version` (e.g., `google.com/intellij/v1`).
  2291. func (c *DebuggerDebuggeesBreakpointsListCall) ClientVersion(clientVersion string) *DebuggerDebuggeesBreakpointsListCall {
  2292. c.urlParams_.Set("clientVersion", clientVersion)
  2293. return c
  2294. }
  2295. // IncludeAllUsers sets the optional parameter "includeAllUsers": When
  2296. // set to `true`, the response includes the list of breakpoints set
  2297. // by
  2298. // any user. Otherwise, it includes only breakpoints set by the caller.
  2299. func (c *DebuggerDebuggeesBreakpointsListCall) IncludeAllUsers(includeAllUsers bool) *DebuggerDebuggeesBreakpointsListCall {
  2300. c.urlParams_.Set("includeAllUsers", fmt.Sprint(includeAllUsers))
  2301. return c
  2302. }
  2303. // IncludeInactive sets the optional parameter "includeInactive": When
  2304. // set to `true`, the response includes active and inactive
  2305. // breakpoints. Otherwise, it includes only active breakpoints.
  2306. func (c *DebuggerDebuggeesBreakpointsListCall) IncludeInactive(includeInactive bool) *DebuggerDebuggeesBreakpointsListCall {
  2307. c.urlParams_.Set("includeInactive", fmt.Sprint(includeInactive))
  2308. return c
  2309. }
  2310. // StripResults sets the optional parameter "stripResults": This field
  2311. // is deprecated. The following fields are always stripped out of
  2312. // the result: `stack_frames`, `evaluated_expressions` and
  2313. // `variable_table`.
  2314. func (c *DebuggerDebuggeesBreakpointsListCall) StripResults(stripResults bool) *DebuggerDebuggeesBreakpointsListCall {
  2315. c.urlParams_.Set("stripResults", fmt.Sprint(stripResults))
  2316. return c
  2317. }
  2318. // WaitToken sets the optional parameter "waitToken": A wait token that,
  2319. // if specified, blocks the call until the breakpoints
  2320. // list has changed, or a server selected timeout has expired. The
  2321. // value
  2322. // should be set from the last response. The error
  2323. // code
  2324. // `google.rpc.Code.ABORTED` (RPC) is returned on wait timeout,
  2325. // which
  2326. // should be called again with the same `wait_token`.
  2327. func (c *DebuggerDebuggeesBreakpointsListCall) WaitToken(waitToken string) *DebuggerDebuggeesBreakpointsListCall {
  2328. c.urlParams_.Set("waitToken", waitToken)
  2329. return c
  2330. }
  2331. // Fields allows partial responses to be retrieved. See
  2332. // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  2333. // for more information.
  2334. func (c *DebuggerDebuggeesBreakpointsListCall) Fields(s ...googleapi.Field) *DebuggerDebuggeesBreakpointsListCall {
  2335. c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2336. return c
  2337. }
  2338. // IfNoneMatch sets the optional parameter which makes the operation
  2339. // fail if the object's ETag matches the given value. This is useful for
  2340. // getting updates only after the object has changed since the last
  2341. // request. Use googleapi.IsNotModified to check whether the response
  2342. // error from Do is the result of In-None-Match.
  2343. func (c *DebuggerDebuggeesBreakpointsListCall) IfNoneMatch(entityTag string) *DebuggerDebuggeesBreakpointsListCall {
  2344. c.ifNoneMatch_ = entityTag
  2345. return c
  2346. }
  2347. // Context sets the context to be used in this call's Do method. Any
  2348. // pending HTTP request will be aborted if the provided context is
  2349. // canceled.
  2350. func (c *DebuggerDebuggeesBreakpointsListCall) Context(ctx context.Context) *DebuggerDebuggeesBreakpointsListCall {
  2351. c.ctx_ = ctx
  2352. return c
  2353. }
  2354. // Header returns an http.Header that can be modified by the caller to
  2355. // add HTTP headers to the request.
  2356. func (c *DebuggerDebuggeesBreakpointsListCall) Header() http.Header {
  2357. if c.header_ == nil {
  2358. c.header_ = make(http.Header)
  2359. }
  2360. return c.header_
  2361. }
  2362. func (c *DebuggerDebuggeesBreakpointsListCall) doRequest(alt string) (*http.Response, error) {
  2363. reqHeaders := make(http.Header)
  2364. for k, v := range c.header_ {
  2365. reqHeaders[k] = v
  2366. }
  2367. reqHeaders.Set("User-Agent", c.s.userAgent())
  2368. if c.ifNoneMatch_ != "" {
  2369. reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2370. }
  2371. var body io.Reader = nil
  2372. c.urlParams_.Set("alt", alt)
  2373. c.urlParams_.Set("prettyPrint", "false")
  2374. urls := googleapi.ResolveRelative(c.s.BasePath, "v2/debugger/debuggees/{debuggeeId}/breakpoints")
  2375. urls += "?" + c.urlParams_.Encode()
  2376. req, err := http.NewRequest("GET", urls, body)
  2377. if err != nil {
  2378. return nil, err
  2379. }
  2380. req.Header = reqHeaders
  2381. googleapi.Expand(req.URL, map[string]string{
  2382. "debuggeeId": c.debuggeeId,
  2383. })
  2384. return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2385. }
  2386. // Do executes the "clouddebugger.debugger.debuggees.breakpoints.list" call.
  2387. // Exactly one of *ListBreakpointsResponse or error will be non-nil. Any
  2388. // non-2xx status code is an error. Response headers are in either
  2389. // *ListBreakpointsResponse.ServerResponse.Header or (if a response was
  2390. // returned at all) in error.(*googleapi.Error).Header. Use
  2391. // googleapi.IsNotModified to check whether the returned error was
  2392. // because http.StatusNotModified was returned.
  2393. func (c *DebuggerDebuggeesBreakpointsListCall) Do(opts ...googleapi.CallOption) (*ListBreakpointsResponse, error) {
  2394. gensupport.SetOptions(c.urlParams_, opts...)
  2395. res, err := c.doRequest("json")
  2396. if res != nil && res.StatusCode == http.StatusNotModified {
  2397. if res.Body != nil {
  2398. res.Body.Close()
  2399. }
  2400. return nil, &googleapi.Error{
  2401. Code: res.StatusCode,
  2402. Header: res.Header,
  2403. }
  2404. }
  2405. if err != nil {
  2406. return nil, err
  2407. }
  2408. defer googleapi.CloseBody(res)
  2409. if err := googleapi.CheckResponse(res); err != nil {
  2410. return nil, err
  2411. }
  2412. ret := &ListBreakpointsResponse{
  2413. ServerResponse: googleapi.ServerResponse{
  2414. Header: res.Header,
  2415. HTTPStatusCode: res.StatusCode,
  2416. },
  2417. }
  2418. target := &ret
  2419. if err := gensupport.DecodeResponse(target, res); err != nil {
  2420. return nil, err
  2421. }
  2422. return ret, nil
  2423. // {
  2424. // "description": "Lists all breakpoints for the debuggee.",
  2425. // "flatPath": "v2/debugger/debuggees/{debuggeeId}/breakpoints",
  2426. // "httpMethod": "GET",
  2427. // "id": "clouddebugger.debugger.debuggees.breakpoints.list",
  2428. // "parameterOrder": [
  2429. // "debuggeeId"
  2430. // ],
  2431. // "parameters": {
  2432. // "action.value": {
  2433. // "description": "Only breakpoints with the specified action will pass the filter.",
  2434. // "enum": [
  2435. // "CAPTURE",
  2436. // "LOG"
  2437. // ],
  2438. // "location": "query",
  2439. // "type": "string"
  2440. // },
  2441. // "clientVersion": {
  2442. // "description": "The client version making the call.\nSchema: `domain/type/version` (e.g., `google.com/intellij/v1`).",
  2443. // "location": "query",
  2444. // "type": "string"
  2445. // },
  2446. // "debuggeeId": {
  2447. // "description": "ID of the debuggee whose breakpoints to list.",
  2448. // "location": "path",
  2449. // "required": true,
  2450. // "type": "string"
  2451. // },
  2452. // "includeAllUsers": {
  2453. // "description": "When set to `true`, the response includes the list of breakpoints set by\nany user. Otherwise, it includes only breakpoints set by the caller.",
  2454. // "location": "query",
  2455. // "type": "boolean"
  2456. // },
  2457. // "includeInactive": {
  2458. // "description": "When set to `true`, the response includes active and inactive\nbreakpoints. Otherwise, it includes only active breakpoints.",
  2459. // "location": "query",
  2460. // "type": "boolean"
  2461. // },
  2462. // "stripResults": {
  2463. // "description": "This field is deprecated. The following fields are always stripped out of\nthe result: `stack_frames`, `evaluated_expressions` and `variable_table`.",
  2464. // "location": "query",
  2465. // "type": "boolean"
  2466. // },
  2467. // "waitToken": {
  2468. // "description": "A wait token that, if specified, blocks the call until the breakpoints\nlist has changed, or a server selected timeout has expired. The value\nshould be set from the last response. The error code\n`google.rpc.Code.ABORTED` (RPC) is returned on wait timeout, which\nshould be called again with the same `wait_token`.",
  2469. // "location": "query",
  2470. // "type": "string"
  2471. // }
  2472. // },
  2473. // "path": "v2/debugger/debuggees/{debuggeeId}/breakpoints",
  2474. // "response": {
  2475. // "$ref": "ListBreakpointsResponse"
  2476. // },
  2477. // "scopes": [
  2478. // "https://www.googleapis.com/auth/cloud-platform",
  2479. // "https://www.googleapis.com/auth/cloud_debugger"
  2480. // ]
  2481. // }
  2482. }
  2483. // method id "clouddebugger.debugger.debuggees.breakpoints.set":
  2484. type DebuggerDebuggeesBreakpointsSetCall struct {
  2485. s *Service
  2486. debuggeeId string
  2487. breakpoint *Breakpoint
  2488. urlParams_ gensupport.URLParams
  2489. ctx_ context.Context
  2490. header_ http.Header
  2491. }
  2492. // Set: Sets the breakpoint to the debuggee.
  2493. func (r *DebuggerDebuggeesBreakpointsService) Set(debuggeeId string, breakpoint *Breakpoint) *DebuggerDebuggeesBreakpointsSetCall {
  2494. c := &DebuggerDebuggeesBreakpointsSetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2495. c.debuggeeId = debuggeeId
  2496. c.breakpoint = breakpoint
  2497. return c
  2498. }
  2499. // ClientVersion sets the optional parameter "clientVersion": The client
  2500. // version making the call.
  2501. // Schema: `domain/type/version` (e.g., `google.com/intellij/v1`).
  2502. func (c *DebuggerDebuggeesBreakpointsSetCall) ClientVersion(clientVersion string) *DebuggerDebuggeesBreakpointsSetCall {
  2503. c.urlParams_.Set("clientVersion", clientVersion)
  2504. return c
  2505. }
  2506. // Fields allows partial responses to be retrieved. See
  2507. // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  2508. // for more information.
  2509. func (c *DebuggerDebuggeesBreakpointsSetCall) Fields(s ...googleapi.Field) *DebuggerDebuggeesBreakpointsSetCall {
  2510. c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2511. return c
  2512. }
  2513. // Context sets the context to be used in this call's Do method. Any
  2514. // pending HTTP request will be aborted if the provided context is
  2515. // canceled.
  2516. func (c *DebuggerDebuggeesBreakpointsSetCall) Context(ctx context.Context) *DebuggerDebuggeesBreakpointsSetCall {
  2517. c.ctx_ = ctx
  2518. return c
  2519. }
  2520. // Header returns an http.Header that can be modified by the caller to
  2521. // add HTTP headers to the request.
  2522. func (c *DebuggerDebuggeesBreakpointsSetCall) Header() http.Header {
  2523. if c.header_ == nil {
  2524. c.header_ = make(http.Header)
  2525. }
  2526. return c.header_
  2527. }
  2528. func (c *DebuggerDebuggeesBreakpointsSetCall) doRequest(alt string) (*http.Response, error) {
  2529. reqHeaders := make(http.Header)
  2530. for k, v := range c.header_ {
  2531. reqHeaders[k] = v
  2532. }
  2533. reqHeaders.Set("User-Agent", c.s.userAgent())
  2534. var body io.Reader = nil
  2535. body, err := googleapi.WithoutDataWrapper.JSONReader(c.breakpoint)
  2536. if err != nil {
  2537. return nil, err
  2538. }
  2539. reqHeaders.Set("Content-Type", "application/json")
  2540. c.urlParams_.Set("alt", alt)
  2541. c.urlParams_.Set("prettyPrint", "false")
  2542. urls := googleapi.ResolveRelative(c.s.BasePath, "v2/debugger/debuggees/{debuggeeId}/breakpoints/set")
  2543. urls += "?" + c.urlParams_.Encode()
  2544. req, err := http.NewRequest("POST", urls, body)
  2545. if err != nil {
  2546. return nil, err
  2547. }
  2548. req.Header = reqHeaders
  2549. googleapi.Expand(req.URL, map[string]string{
  2550. "debuggeeId": c.debuggeeId,
  2551. })
  2552. return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2553. }
  2554. // Do executes the "clouddebugger.debugger.debuggees.breakpoints.set" call.
  2555. // Exactly one of *SetBreakpointResponse or error will be non-nil. Any
  2556. // non-2xx status code is an error. Response headers are in either
  2557. // *SetBreakpointResponse.ServerResponse.Header or (if a response was
  2558. // returned at all) in error.(*googleapi.Error).Header. Use
  2559. // googleapi.IsNotModified to check whether the returned error was
  2560. // because http.StatusNotModified was returned.
  2561. func (c *DebuggerDebuggeesBreakpointsSetCall) Do(opts ...googleapi.CallOption) (*SetBreakpointResponse, error) {
  2562. gensupport.SetOptions(c.urlParams_, opts...)
  2563. res, err := c.doRequest("json")
  2564. if res != nil && res.StatusCode == http.StatusNotModified {
  2565. if res.Body != nil {
  2566. res.Body.Close()
  2567. }
  2568. return nil, &googleapi.Error{
  2569. Code: res.StatusCode,
  2570. Header: res.Header,
  2571. }
  2572. }
  2573. if err != nil {
  2574. return nil, err
  2575. }
  2576. defer googleapi.CloseBody(res)
  2577. if err := googleapi.CheckResponse(res); err != nil {
  2578. return nil, err
  2579. }
  2580. ret := &SetBreakpointResponse{
  2581. ServerResponse: googleapi.ServerResponse{
  2582. Header: res.Header,
  2583. HTTPStatusCode: res.StatusCode,
  2584. },
  2585. }
  2586. target := &ret
  2587. if err := gensupport.DecodeResponse(target, res); err != nil {
  2588. return nil, err
  2589. }
  2590. return ret, nil
  2591. // {
  2592. // "description": "Sets the breakpoint to the debuggee.",
  2593. // "flatPath": "v2/debugger/debuggees/{debuggeeId}/breakpoints/set",
  2594. // "httpMethod": "POST",
  2595. // "id": "clouddebugger.debugger.debuggees.breakpoints.set",
  2596. // "parameterOrder": [
  2597. // "debuggeeId"
  2598. // ],
  2599. // "parameters": {
  2600. // "clientVersion": {
  2601. // "description": "The client version making the call.\nSchema: `domain/type/version` (e.g., `google.com/intellij/v1`).",
  2602. // "location": "query",
  2603. // "type": "string"
  2604. // },
  2605. // "debuggeeId": {
  2606. // "description": "ID of the debuggee where the breakpoint is to be set.",
  2607. // "location": "path",
  2608. // "required": true,
  2609. // "type": "string"
  2610. // }
  2611. // },
  2612. // "path": "v2/debugger/debuggees/{debuggeeId}/breakpoints/set",
  2613. // "request": {
  2614. // "$ref": "Breakpoint"
  2615. // },
  2616. // "response": {
  2617. // "$ref": "SetBreakpointResponse"
  2618. // },
  2619. // "scopes": [
  2620. // "https://www.googleapis.com/auth/cloud-platform",
  2621. // "https://www.googleapis.com/auth/cloud_debugger"
  2622. // ]
  2623. // }
  2624. }