Skip to content

Commit a695637

Browse files
jmdobrychingor13
authored andcommitted
samples: Clean up DLP region tags. (#1051)
1 parent 836659d commit a695637

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

dlp/snippets/snippets/src/main/java/com/example/dlp/DeIdentification.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ private static void deIdentifyWithMask(
4646
String string,
4747
Character maskingCharacter,
4848
int numberToMask) {
49-
// [START dlp_deidentify_mask]
49+
// [START dlp_deidentify_masking]
5050
/**
5151
* Deidentify a string by masking sensitive information with a character using the DLP API.
5252
* @param string The string to deidentify.
@@ -113,7 +113,7 @@ private static void deIdentifyWithMask(
113113
} catch (Exception e) {
114114
System.out.println("Error in deidentifyWithMask: " + e.getMessage());
115115
}
116-
// [END dlp_deidentify_mask]
116+
// [END dlp_deidentify_masking]
117117
}
118118

119119
private static void deIdentifyWithFpe(

dlp/snippets/snippets/src/main/java/com/example/dlp/Metadata.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ private static void listInfoTypes(String category, String languageCode) throws E
4949
}
5050

5151
private static void listRootCategories(String languageCode) throws Exception {
52-
// [START dlp_list_root_categories]
52+
// [START dlp_list_categories]
5353
// Instantiate a DLP client
5454
try (DlpServiceClient dlpClient = DlpServiceClient.create()) {
5555
// The BCP-47 language code to use, e.g. 'en-US'
@@ -61,7 +61,7 @@ private static void listRootCategories(String languageCode) throws Exception {
6161
System.out.println("Display name : " + categoryDescription.getDisplayName());
6262
}
6363
}
64-
// [END dlp_list_root_categories]
64+
// [END dlp_list_categories]
6565
}
6666

6767
/** Retrieve infoTypes. */

dlp/snippets/snippets/src/main/java/com/example/dlp/RiskAnalysis.java

+4-4
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ public class RiskAnalysis {
5555
private static void calculateNumericalStats(
5656
String projectId, String datasetId, String tableId, String columnName)
5757
throws Exception {
58-
// [START dlp_numerical_stats_analysis]
58+
// [START dlp_numerical_stats]
5959

6060
/**
6161
* Calculate numerical statistics for a column in a BigQuery table using the DLP API.
@@ -128,13 +128,13 @@ private static void calculateNumericalStats(
128128
} catch (Exception e) {
129129
System.out.println("Error in numericalStatsAnalysis: " + e.getMessage());
130130
}
131-
// [END dlp_numerical_stats_analysis]
131+
// [END dlp_numerical_stats]
132132
}
133133

134134
private static void calculateCategoricalStats(
135135
String projectId, String datasetId, String tableId, String columnName)
136136
throws Exception {
137-
// [START dlp_categorical_stats_analysis]
137+
// [START dlp_categorical_stats]
138138
/**
139139
* Calculate categorical statistics for a column in a BigQuery table using the DLP API.
140140
* @param projectId The Google Cloud Platform project ID to run the API call under.
@@ -206,7 +206,7 @@ private static void calculateCategoricalStats(
206206
} catch (Exception e) {
207207
System.out.println("Error in categoricalStatsAnalysis: " + e.getMessage());
208208
}
209-
// [END dlp_categorical_stats_analysis]
209+
// [END dlp_categorical_stats]
210210
}
211211

212212
private static void calculateKAnonymity(

0 commit comments

Comments
 (0)