|
1 | 1 | /* |
2 | | - Copyright 2017, Google, Inc. |
3 | | -
|
4 | | - Licensed under the Apache License, Version 2.0 (the "License"); |
5 | | - you may not use this file except in compliance with the License. |
6 | | - You may obtain a copy of the License at |
7 | | -
|
8 | | - http://www.apache.org/licenses/LICENSE-2.0 |
9 | | -
|
10 | | - Unless required by applicable law or agreed to in writing, software |
11 | | - distributed under the License is distributed on an "AS IS" BASIS, |
12 | | - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
13 | | - See the License for the specific language governing permissions and |
14 | | - limitations under the License. |
15 | | -*/ |
| 2 | + * Copyright 2017 Google Inc. |
| 3 | + * |
| 4 | + * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | + * you may not use this file except in compliance with the License. |
| 6 | + * You may obtain a copy of the License at |
| 7 | + * |
| 8 | + * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | + * |
| 10 | + * Unless required by applicable law or agreed to in writing, software |
| 11 | + * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | + * See the License for the specific language governing permissions and |
| 14 | + * limitations under the License. |
| 15 | + */ |
16 | 16 |
|
17 | 17 | package com.example.monitoring; |
18 | 18 |
|
| 19 | +//CHECKSTYLE OFF: VariableDeclarationUsageDistance |
19 | 20 | // [START monitoring_quickstart] |
| 21 | + |
20 | 22 | import com.google.api.Metric; |
21 | 23 | import com.google.api.MonitoredResource; |
22 | | - |
23 | | -// Imports the Google Cloud client library |
24 | 24 | import com.google.cloud.monitoring.v3.MetricServiceClient; |
25 | | - |
26 | 25 | import com.google.monitoring.v3.CreateTimeSeriesRequest; |
27 | 26 | import com.google.monitoring.v3.Point; |
28 | 27 | import com.google.monitoring.v3.ProjectName; |
29 | 28 | import com.google.monitoring.v3.TimeInterval; |
30 | 29 | import com.google.monitoring.v3.TimeSeries; |
31 | 30 | import com.google.monitoring.v3.TypedValue; |
32 | 31 | import com.google.protobuf.util.Timestamps; |
33 | | - |
34 | 32 | import java.util.ArrayList; |
35 | 33 | import java.util.HashMap; |
36 | 34 | import java.util.List; |
37 | 35 | import java.util.Map; |
38 | 36 |
|
| 37 | +// Imports the Google Cloud client library |
| 38 | + |
39 | 39 | public class QuickstartSample { |
| 40 | + |
40 | 41 | public static void main(String... args) throws Exception { |
41 | 42 | // Your Google Cloud Platform project ID |
42 | 43 | String projectId = System.getProperty("projectId"); |
@@ -105,3 +106,4 @@ public static void main(String... args) throws Exception { |
105 | 106 | } |
106 | 107 | } |
107 | 108 | // [END monitoring_quickstart] |
| 109 | +//CHECKSTYLE ON: VariableDeclarationUsageDistance |
0 commit comments