Skip to content

Commit ab4b52d

Browse files
authored
Clean up readme (#356)
1 parent 235a923 commit ab4b52d

File tree

1 file changed

+18
-31
lines changed
  • src/main/java/com/esri/samples/symbology/symbol_dictionary

1 file changed

+18
-31
lines changed
Lines changed: 18 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,56 +1,43 @@
11
<h1>Symbol Dictionary</h1>
22

3-
<p>Find symbols within mil2525d specification that match a keyword.</p>
3+
<p>Find symbols within the mil2525d specification that match a keyword.</p>
44

55
<p><img src="SymbolDictionary.png"/></p>
6-
7-
<p>There are five ways to search through a Symbol Dictionary:
8-
- Name
9-
- Tags
10-
- Symbol Class
11-
- Category
12-
- Key</p>
6+
7+
<h2>Use case</h2>
8+
9+
<p>You can use support for military symbology to allow users to report changes in the field using the correct military symbols.</p>
1310

1411
<h2>How to use the sample</h2>
1512

16-
<p>By default, leaving the fields blank and hitting search will find all symbols.</p>
13+
<p>By default, leaving the fields blank and searching will return all symbols.</p>
1714

18-
<p>To search for certain symbols:
19-
- enter text into one or multiple seach boxes and hit <code>search for symbols</code>
20-
- this will seach for symbols containing the information that was entered</p>
15+
<p>To filter symbols, enter text into one or multiple seach boxes and click the Search for Symbols button.</p>
2116

22-
<p>Clear button:
23-
- will clear any previous search results and start fresh</p>
17+
<p>Click the Clear button to clear previous search results.</p>
2418

2519
<h2>How it works</h2>
2620

27-
<p>How to search through a <code>SymbolDictionary</code>:</p>
28-
2921
<ol>
30-
<li>Create a symbol dictionary with the mil2525d specification, <code>SymbolDictionary("mil2525d")</code></li>
31-
<li>Load the dictionary asynchronously, <code>DictionarySymbol.loadAsync()</code>
32-
<ul><li>this will allows the application to continue working while the dictionary loads all symbol primitives found within the mil2525d specification</li></ul></li>
33-
<li>Create search parameters for the dictionary, <code>StyleSymbolSearchParameters()</code>.</li>
34-
<li>Set the parameters to search through the dictionary.
35-
<ul><li>Name, <code>StyleSymbolSearchParameters.getNames().add()</code></li>
36-
<li>Tag, <code>StyleSymbolSearchParameters.getTags().add()</code></li>
37-
<li>Symbol Class, <code>StyleSymbolSearchParameters.getSymbolClasses().add()</code></li>
38-
<li>Category, <code>StyleSymbolSearchParameters.getCategories().add()</code></li>
39-
<li>Key, <code>StyleSymbolSearchParameters.getKeys().add()</code></li></ul></li>
40-
<li>Search through dictionary using parameters, <code>DictionarySymbol.searchSymbolsAsync(StyleSymbolSearchParameters)</code>.</li>
41-
<li>Cycle through the <code>StyleSymbolSearchResult</code> list that was returned and display it to screen.
42-
<ul><li>get <code>CimSymbol</code>,<code>StyleSymbolSearchResult.getSymbol()</code>, and create an image from it, <code>CimSymbol.createSwatchAsync()</code></li>
43-
<li>use other get methods for the symbol's name, tags, symbolClass, category, and key, like <code>StyleSymbolSearchResult.getName()</code></li></ul></li>
22+
<li>Create a symbol dictionary with the mil2525d specification by passing the string "mil2525d" to the
23+
<code>SymbolDictionary</code> constructor.</li>
24+
<li>Create <code>StyleSymbolSearchParameters</code>.</li>
25+
<li>Add members to the names, tags, symbolClasses, categories, and keys list fields of the search parameters.</li>
26+
<li>Search for symbols using the parameters with <code>symbolDictionary.searchSymbolsAsync(styleSymbolSearchParameters)</code>.</li>
27+
<li>Get the <code>Symbol</code> from the list of returned <code>StyleSymbolSearchResult</code>.</li>
4428
</ol>
4529

4630
<h2>Relevant API</h2>
4731

4832
<ul>
49-
<li>CimSymbol</li>
5033
<li>StyleSymbolSearchParameters</li>
5134
<li>StyleSymbolSearchResult</li>
35+
<li>Symbol</li>
5236
<li>SymbolDictionary</li>
5337
</ul>
5438

39+
<h2>Tags</h2>
5540

41+
<p>CIM, MIL-STD-2525B, MIL-STD-2525C, MIL-STD-2525D, defense, look up, mil2525b, mil2525c, mil2525d, military, military
42+
symbology, symbology</p>
5643

0 commit comments

Comments
 (0)