https://protegewiki.stanford.edu/index.php?title=UseProtegeFormsInApplications&feed=atom&action=history
UseProtegeFormsInApplications - Revision history
2024-03-29T14:02:13Z
Revision history for this page on the wiki
MediaWiki 1.27.7
https://protegewiki.stanford.edu/index.php?title=UseProtegeFormsInApplications&diff=2291&oldid=prev
JenniferVendetti at 23:50, June 3, 2008
2008-06-03T23:50:25Z
<p></p>
<table class="diff diff-contentalign-left" data-mw="interface">
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr style='vertical-align: top;' lang='en'>
<td colspan='2' style="background-color: white; color:black; text-align: center;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black; text-align: center;">Revision as of 23:50, June 3, 2008</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l46" >Line 46:</td>
<td colspan="2" class="diff-lineno">Line 46:</td></tr>
<tr><td class='diff-marker'> </td><td style="background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;"><div>'''See Also:'''</div></td><td class='diff-marker'> </td><td style="background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;"><div>'''See Also:'''</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;"></td><td class='diff-marker'> </td><td style="background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div>[[UseTabInApplication|Using a Protege tab plub-in in your own application]]</div></td><td class='diff-marker'>+</td><td style="color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div>[[UseTabInApplication|Using a Protege tab plub-in in your own application<ins class="diffchange diffchange-inline">]]<br /><br /></ins></div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div> </div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins class="diffchange diffchange-inline">[[Category:Protege developer documentation</ins>]]</div></td></tr>
</table>
JenniferVendetti
https://protegewiki.stanford.edu/index.php?title=UseProtegeFormsInApplications&diff=2289&oldid=prev
JenniferVendetti at 22:40, June 3, 2008
2008-06-03T22:40:57Z
<p></p>
<table class="diff diff-contentalign-left" data-mw="interface">
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr style='vertical-align: top;' lang='en'>
<td colspan='2' style="background-color: white; color:black; text-align: center;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black; text-align: center;">Revision as of 22:40, June 3, 2008</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l42" >Line 42:</td>
<td colspan="2" class="diff-lineno">Line 42:</td></tr>
<tr><td class='diff-marker'> </td><td style="background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;"><div>}</div></td><td class='diff-marker'> </td><td style="background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;"><div>}</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;"><div></pre></code></div></td><td class='diff-marker'> </td><td style="background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;"><div></pre></code></div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"></ins></div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"></ins></div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;">'''See Also:'''</ins></div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"></ins></div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;">[[UseTabInApplication|Using a Protege tab plub-in in your own application]]</ins></div></td></tr>
</table>
JenniferVendetti
https://protegewiki.stanford.edu/index.php?title=UseProtegeFormsInApplications&diff=2288&oldid=prev
JenniferVendetti: migrated this page from protege web site
2008-06-03T22:22:34Z
<p>migrated this page from protege web site</p>
<p><b>New page</b></p><div>= Using Protege Forms in Other Applications =<br />
<br />
Protege forms can be used by external applications to display knowledge base instances. These applications may have no need to display any of the rest of the Protege user interface such as the main frame, Classes tab, etc.<br />
<br />
Below is an example of how to display an instance from within your application. You first load the Protege project file and then pass the name of the instance you wish to display to the showInstance method of the ProjectView object.<br />
<br />
''Please note that the following code works with both Protege-Frames and Protege-OWL ontologies.''<br />
<br />
<code><pre><br />
package app;<br />
<br />
import java.util.*;<br />
import javax.swing.*;<br />
import edu.stanford.smi.protege.model.*;<br />
<br />
public class MyExternalApplication {<br />
<br />
private static String projectFileName = "c:\\temp\\newspaper\\newspaper.pprj";<br />
private static String instanceName = "instance_00015";<br />
<br />
public static void main(String[] args) {<br />
Collection errors = new ArrayList();<br />
Project project = new Project(projectFileName, errors);<br />
<br />
if (errors.isEmpty()) {<br />
<br />
// show an instance in a top level frame<br />
project.show(instanceName);<br />
<br />
// create a panel that contains and instance form and display it in my top level frame<br />
Instance instance = project.getKnowledgeBase().getInstance(instanceName);<br />
JComponent panel = (JComponent) project.createRuntimeClsWidget(instance);<br />
JFrame frame = new JFrame("My Application Frame");<br />
frame.getContentPane().add(panel);<br />
frame.pack();<br />
frame.show();<br />
<br />
} else {<br />
System.out.println("There were load errors");<br />
}<br />
}<br />
}<br />
</pre></code></div>
JenniferVendetti