Skip to content

Commit 6dadab4

Browse files
authored
Update java-hand-text.md
1 parent 8cb9989 commit 6dadab4

File tree

1 file changed

+6
-13
lines changed

1 file changed

+6
-13
lines changed

articles/cognitive-services/Computer-vision/QuickStarts/java-hand-text.md

Lines changed: 6 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
title: "Quickstart: Computer Vision 2.0 and 2.1 - Extract printed and handwritten text - REST, Java"
2+
title: "Quickstart: Computer Vision 2.1 and 3.0 - Extract printed and handwritten text - REST, Java"
33
titleSuffix: "Azure Cognitive Services"
44
description: In this quickstart, you extract printed and handwritten text from an image using the Computer Vision API with Java.
55
services: cognitive-services
@@ -80,14 +80,10 @@ To create and run the sample, do the following steps:
8080

8181
```java
8282
public class Main {
83-
// **********************************************
84-
// *** Update or verify the following values. ***
85-
// **********************************************
86-
8783
// Add your Computer Vision subscription key and endpoint to your environment variables.
8884
// After setting, close and then re-open your command shell or project for the changes to take effect.
89-
String subscriptionKey = System.getenv("COMPUTER_VISION_SUBSCRIPTION_KEY");
90-
String endpoint = ("COMPUTER_VISION_ENDPOINT");
85+
private static String subscriptionKey = System.getenv("COMPUTER_VISION_SUBSCRIPTION_KEY");
86+
private static String endpoint = System.getenv("COMPUTER_VISION_ENDPOINT");
9187

9288
private static final String uriBase = endpoint +
9389
"vision/v2.1/read/core/asyncBatchAnalyze";
@@ -224,20 +220,17 @@ To create and run the sample, do the following steps:
224220
```java
225221

226222
public class Main {
227-
// **********************************************
228-
// *** Update or verify the following values. ***
229-
// **********************************************
230223

231224
// Add your Computer Vision subscription key and endpoint to your environment variables.
232225
// After setting, close and then re-open your command shell or project for the changes to take effect.
233226
private static String subscriptionKey = System.getenv("COMPUTER_VISION_SUBSCRIPTION_KEY");
234227
private static String endpoint = System.getenv("COMPUTER_VISION_ENDPOINT");
235228

236229
// Set the language that you want to recognize
237-
private static String language = "en"; // Accepted values are "en" for English, or "es" for Spanish
230+
// Accepted values are "en" for English, or "es" for Spanish
231+
private static String language = "en";
238232

239-
private static String uriBase = endpoint +
240-
"/vision/v3.0-preview/read/analyze";
233+
private static String uriBase = endpoint + "/vision/v3.0-preview/read/analyze";
241234

242235
private static String imageToAnalyze =
243236
"https://upload.wikimedia.org/wikipedia/commons/thumb/d/dd/" +

0 commit comments

Comments
 (0)