tag:blogger.com,1999:blog-328752962024-03-20T01:02:20.928+05:30Mahesh Mhetre 's BlogsMahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.comBlogger17125tag:blogger.com,1999:blog-32875296.post-35818148275905848642014-08-21T12:34:00.001+05:302014-08-21T12:34:04.311+05:30Windchill Stickiness in 10.x<div dir="ltr" style="text-align: left;" trbidi="on">
<div class="MsoNormal">
<div dir="ltr" style="line-height: 1; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">In my recent post </span><a href="http://maheshmhetre.blogspot.com/2013/04/windchill-stickiness.html" style="line-height: 1; text-decoration: none;"><span style="color: blue; font-family: Arial; font-size: 15px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">Windchill Stickiness</span></a><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> I wrote about the Windchill Stickiness and how to clear in Windchill 9.1. Here we will discuss how to clear Windchill Stickiness in Windchill 10.x</span></div>
<b style="font-weight: normal;"><br /></b>
<div dir="ltr" style="line-height: 1; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><b>How to reset Windchill Stickiness in 10.x?</b></span></div>
<ol style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"><div dir="ltr" style="line-height: 1; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">Navigate to </span><span style="background-color: transparent; color: blue; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">http://<host>/<webapp>/app/netmarkets/jsp/user/utilitiesList.jsp</webapp></host></span></div>
</li>
</ol>
<div dir="ltr" style="line-height: 1; margin-bottom: 0pt; margin-left: 36pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><img height="241px;" src="https://lh6.googleusercontent.com/7L7yxWnmhL_Z1jqcCqEUjjqTEWrr1WSJ6ZUyKb8kbqCoIzBzJhF0Wdqu-0EB_CNWoSTjwqZz-rmwHqqEJcy3c-up075nTtpBsTWsgwtY-DIDN8oDNcOdYEmAOIq-ET2_HhDHINWUGps" style="-webkit-transform: rotate(0.00rad); border: none; transform: rotate(0.00rad);" width="605px;" /></span></div>
<ol start="2" style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"><div dir="ltr" style="line-height: 1; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">Click “Reset Server Stickiness”. It will ask the confirmation</span></div>
</li>
</ol>
<div dir="ltr" style="line-height: 1; margin-bottom: 0pt; margin-left: 36pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;"><img height="289px;" src="https://lh4.googleusercontent.com/wYWT37_V1a_JVStgELP0mAP_m1U28WhtwEdSdQw6yKhcu0cbJPoxli9mUob1QHqiyMlUBU_IWcDCKgOScQoKFRVItIMXxHmenzsTq_Q-_s0SaQPKbmCh6urH_jtzlIuSJATEKhBZ4ps" style="-webkit-transform: rotate(0.00rad); border: none; transform: rotate(0.00rad);" width="497px;" /></span></div>
<br />
<ol start="3" style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"><div dir="ltr" style="line-height: 1; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">Click OK to clear server stickiness</span></div>
</li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"><div dir="ltr" style="line-height: 1; margin-bottom: 0pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline; white-space: pre-wrap;">To remove all client stickiness, delete all your temporary internet files (usually in the Tools menu), close all browser windows, and restart the browser.</span></div>
</li>
</ol>
</div>
</div>
Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com1tag:blogger.com,1999:blog-32875296.post-28064402297338653142014-07-30T15:03:00.000+05:302014-07-30T15:03:23.756+05:30Soft Type – How to get type definition reference id<div dir="ltr" style="text-align: left;" trbidi="on">
<div class="MsoNormal">
When we want to find
the list of soft type objects and with the help of QuerySpec in Windchill, we
need to use soft type’s type definition reference id in the QuerySpec
condition.<o:p></o:p></div>
<div class="MsoNormal">
Below code snippet
will be useful in writing this QuerySpec<o:p></o:p></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="background: silver; font-family: Consolas; font-size: 10pt;">TypeDefinitionReference</span><span style="font-family: Consolas; font-size: 10pt;"> typeDefRef = TypedUtility.<i>getTypeDefinitionReference</i>(</span><span style="color: #2a00ff; font-family: Consolas; font-size: 10.0pt; mso-ansi-language: EN-US;">"com.maheshmhetre.epmdoc.TestEPMDocument"</span><span style="font-family: Consolas; font-size: 10pt;">);</span><span style="font-family: Consolas; font-size: 10.0pt; mso-ansi-language: EN-US;"><o:p></o:p></span></div>
<div class="MsoNormal">
<b><span style="color: #7f0055; font-family: Consolas; font-size: 10.0pt; mso-ansi-language: EN-US;">if</span></b><span style="font-family: Consolas; font-size: 10pt;"> (typeDefRef != </span><b><span style="color: #7f0055; font-family: Consolas; font-size: 10.0pt; mso-ansi-language: EN-US;">null</span></b><span style="font-family: Consolas; font-size: 10pt;">) {</span><span style="font-family: Consolas; font-size: 10.0pt; mso-ansi-language: EN-US;"><o:p></o:p></span></div>
<div class="MsoNormal" style="mso-layout-grid-align: none; text-autospace: none; text-indent: 35.4pt;">
<span style="font-family: Consolas; font-size: 10pt;">qs.appendWhere(</span><b><span style="color: #7f0055; font-family: Consolas; font-size: 10.0pt; mso-ansi-language: EN-US;">new</span></b><span style="font-family: Consolas; font-size: 10pt;"> SearchCondition(EPMDocument.</span><b><span style="color: #7f0055; font-family: Consolas; font-size: 10.0pt; mso-ansi-language: EN-US;">class</span></b><span style="font-family: Consolas; font-size: 10pt;">,</span><span style="font-family: Consolas; font-size: 10.0pt; mso-ansi-language: EN-US;"><o:p></o:p></span></div>
<div class="MsoNormal" style="margin-left: 141.6pt; mso-layout-grid-align: none; text-autospace: none;">
<span style="color: #2a00ff; font-family: Consolas; font-size: 10.0pt; mso-ansi-language: EN-US;">"typeDefinitionReference.key.id"</span><span style="font-family: Consolas; font-size: 10pt;">, <o:p></o:p></span></div>
<div class="MsoNormal" style="margin-left: 141.6pt; mso-layout-grid-align: none; text-autospace: none;">
<span style="font-family: Consolas; font-size: 10pt;">SearchCondition.</span><i><span style="color: #0000c0; font-family: Consolas; font-size: 10.0pt; mso-ansi-language: EN-US;">EQUAL</span></i><span style="font-family: Consolas; font-size: 10pt;">,</span><span style="font-family: Consolas; font-size: 10.0pt; mso-ansi-language: EN-US;"><o:p></o:p></span></div>
<div class="MsoNormal">
<span style="font-family: Consolas; font-size: 10pt;"> typeDefRef.getKey().getId()));</span><span style="font-family: Consolas; font-size: 10.0pt; mso-ansi-language: EN-US;"><o:p></o:p></span></div>
<div class="MsoNormal">
<span style="font-family: Consolas; font-size: 10pt;">}<o:p></o:p></span></div>
<div class="MsoNormal">
<br /></div>
<br />
<div class="MsoNormal">
Here ‘<span style="color: #2a00ff; font-family: Consolas; font-size: 10.0pt; mso-ansi-language: EN-US;">com.maheshmhetre.epmdoc.TestEPMDocument</span>’ is the Internal Name of the soft type. This
value can be retrieved from soft type details from Type and Attribute Manager.<o:p></o:p></div>
</div>
Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com1tag:blogger.com,1999:blog-32875296.post-19744353986764096412013-04-19T10:11:00.000+05:302013-12-06T16:31:16.894+05:30Windchill Part Usage Link<div dir="ltr" style="text-align: left;" trbidi="on">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"></b><br />
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">This is an IteratedUsageLink where a specific WTPart uses a WTPartMaster (actually it will use one of the WTParts associated with the WTPartMaster based on a config spec) and the part uses a specific Quantity (with unit of measure) of the part master as a component of its structure. WTParts can use other parts to build assemblies using the WTPartUsageLink. The WTPartUsageLink’s aggregated Quantity can be used to indicate the amount of the component that is being consumed.</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Note that since the link is between a WTPart and a WTPartMaster it will be necessary to use a config spec (usually WTPartConfigSpec) to select the correct version of the WTPartMaster, which is a WTPart.</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">For example:</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">To build a car there are 4 tires for each car built. For a hammock there might be 2 end ropes that are three feet long.</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><br /></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Part_1 A.1 is dependent on Part_2 master object.</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"><br /></span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><img height="70px;" src="https://lh4.googleusercontent.com/AUzsjHicxSX7Xs1VwTHrOirnvdxOhK2Q5OejrZhsx-kM1G5xM1XLKWbNbFeQq68rZHwE_TjXYCmXO5iEeqxSREm_Eb6nYpDS0L9ub0bWDjHv1coTNn9maW-3" width="320px;" /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Even after new revision/iteration Part_1 B.1 is link to the Part_2 irrespective of Part_2 iteration number i.e. the parent object’s (Part_1) all iterations are always linked to the child’s (Part_2) latest iteration.</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b style="font-weight: normal;"><br /></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b style="font-weight: normal;"><img height="73px;" src="https://lh3.googleusercontent.com/G_fTUriBbANvXABF0rzUBGIHQIX0t_B1w2XHrM26fA7RRidzpkX2E1Y1j9WYewfpxE5q3acrewhHNJzZjgo7_998fI9oZGQNYX8Rle8HcYYWxP978b1GBhOx" width="318px;" /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">Model Diagram:</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b style="font-weight: normal;"><br /></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b style="font-weight: normal;"><img height="324px;" src="https://lh3.googleusercontent.com/ZrgOIJCoKqyr-BRY7YP0YE68FQ3yWPE1-Bg7kxa_saBX7Ob36PyFF3kMhDV-v27LbTsTydyWMfG-aa80xF8ROjf-19X7_ZJd95ijDKUZKWLowNNIE2FghEvj" width="651px;" /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">JavaDoc:</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">URL:</span><a href="http://host/webapp/wt/clients/library/api/wt/part/WTPartUsageLink.html%20" style="text-decoration: none;"><span style="color: black; font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="color: #1155cc; font-family: Arial; font-size: 15px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">http://host/webapp/wt/clients/library/api/wt/part/WTPartUsageLink.html</span></a></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;">wt.part </span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;"><br class="kix-line-break" />Class WTPartUsageLink</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">java.lang.Object</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> wt.fc.WTObject</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> <span class="Apple-tab-span" style="white-space: pre;"> </span>wt.fc.ObjectToObjectLink</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> <span class="Apple-tab-span" style="white-space: pre;"> </span>wt.vc.struct.IteratedUsageLink</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> <span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;">wt.part.WTPartUsageLink</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 16px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">public class </span><span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;">WTPartUsageLink</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">extends IteratedUsageLink</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">implements Externalizable</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">UI Navigations:</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">To see the part usage, navigate to parent part details page -> third level navigations -> Structure -> Product Structure table</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span><img height="313px;" src="https://lh4.googleusercontent.com/phLZKtRcn3MFHymMzEo9YUV1DnL3ZM3ZOXebqTe7Sxo0Ky0BlAzflkmO_gVp-kdR_GKU0mBf599R8GOEYOCiAXwsp7CSTjvUcZvd5JIYvrLTDZHE2ekeG-Mk" width="502px;" /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">API Navigations:</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">To get the usage parts, we need to navigate through this link table. The service APIs are available in WTPartService class.</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><a href="http://host/webapp/wt/clients/library/api/wt/part/WTPartService.html" style="text-decoration: none;"><span style="color: #1155cc; font-family: Arial; font-size: 15px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">http://host/webapp/wt/clients/library/api/wt/part/WTPartService.html</span></a></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">The relevant methods are (Please refer JavaDoc for more details)</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<div dir="ltr">
<table style="border-collapse: collapse; border: none;"><colgroup><col width="122"></col><col width="502"></col></colgroup><tbody>
<tr style="height: 0px;"><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt; text-align: right;">
<span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">QueryResult</span></div>
</td><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"><b>getUsedByWTParts</b></span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">(</span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">WTPartMaster</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> partMaster)</span><span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> Navigates the WTPartUsageLink along the usedBy role, returning a QueryResult of WTParts.</span></div>
</td></tr>
<tr style="height: 0px;"><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt; text-align: right;">
<span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">QueryResult</span></div>
</td><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"><b>getUsesWTPartMasters</b></span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">(</span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">WTPart</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> part)</span><span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> Navigates the WTPartUsageLink along the uses role, returning a QueryResult of WTPartUsageLinks.</span></div>
</td></tr>
<tr style="height: 0px;"><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt; text-align: right;">
<span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Persistable</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">[][][]</span></div>
</td><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;">getUsesWTParts</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">(</span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">WTList</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> parts, </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">ConfigSpec</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> configSpec)</span><span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Navigates from many used-by parts to their uses part masters and applies a ConfigSpec to select the iterations of the uses parts.</span></div>
</td></tr>
</tbody></table>
</div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<div>
<b id="internal-source-marker_0.6620560192968696" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"><br /></span></b></div>
</div>
Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com1tag:blogger.com,1999:blog-32875296.post-68800340827601380712013-04-17T11:50:00.001+05:302013-12-06T16:31:16.923+05:30Windchill Document Dependency Link<div dir="ltr" style="text-align: left;" trbidi="on">
<b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"></b><br />
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">This is a version-specific relationship between two documents i.e. WTDocument to WTDocument link. A reference between two documents can be created to show a dependency on another document. A document may reference some information in another document, so during a create or update, a reference to that document is added. The references relationship has a comment attribute that can be used to explain why the reference exists or what the dependency is.</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">For example:</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">A document is depends on another document.</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"><b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"></b></b></div>
<div dir="ltr" style="display: inline !important; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"><b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;"> </span></b></b></div>
<br />
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Doc1 A.1 is dependent on Doc2 A.1</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"><img height="78px;" src="https://lh6.googleusercontent.com/0o_Z0HKyCFrbnPYbs9nceV2NjNKViDiNzadtNnbc6zpcI0WYgaQQ3sazbzUa-vve6zpiTwEHXErsjGo_4EbPMKDpLQHTuUI_purPCRLdSFTZVnduluMuKgDM" width="326px;" /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span></b></div>
<b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"><br /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span></b>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">After new revision/iteration Doc1 B.1 is dependent on Doc2 B.1</span></b></div>
<b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;">
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"></b></div>
<div dir="ltr" style="display: inline !important; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.41987102990970016" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span><img height="76px;" src="https://lh3.googleusercontent.com/ikca3q4jRcaN5FJV05NPFEe6ZDzSN3ZNnKBs7IrfQi46vnwRbOELHABeJbE4Wk9f0VFgyVJ5Sy_eazcVTY71760N_S791LSG8RrlFS8K58Yesi5ap9ajMBiD" width="321px;" /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<br />
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Doc1 A.1 is dependent on Doc2 A.1. This is a version dependency. If the Doc1 get revised/iterated, the dependent document’s will also get updated.</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">Model Diagram:</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span><img height="295px;" src="https://lh3.googleusercontent.com/D2UOcoWuRbc57pBwuPkpH4QUQPMKCEH19tfn41EmenB_WnhtAp-h-kItD0Hlsc-J3Htw9npe7WITdNtqB5t3GvTPqg27snuiRLLfq8WsexYrMIbZkCDrqVeg" width="570px;" /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;"><br /></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">JavaDoc:</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">URL:</span><a href="http://host/webapp/wt/clients/library/api/wt/doc/WTDocumentDependencyLink.html%20" style="text-decoration: none;"><span style="color: black; font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="color: #1155cc; font-family: Arial; font-size: 15px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">http://host/webapp/wt/clients/library/api/wt/doc/WTDocumentDependencyLink.html</span></a></div>
<br /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;">wt.doc </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;">Class WTDocumentDependencyLink</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">java.lang.Object</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> wt.fc.WTObject</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> <span class="Apple-tab-span" style="white-space: pre;"> </span>wt.fc.ObjectToObjectLink</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> <span class="Apple-tab-span" style="white-space: pre;"> </span>wt.vc.struct.IteratedUsageLink</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> <span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;">wt.doc.WTDocumentDependencyLink</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 16px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">public class </span><span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;">WTDocumentDependencyLink</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">extends IteratedUsageLink</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">implements Externalizable</span></div>
<br /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">UI Navigations:</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">To see the dependent documents, navigate to main document’s details page third level navigations -> Related Objects -> Documents</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">To add the dependent documents, from ‘References Documents’ use ‘Add’ or ‘Associate New’ table level action on main document. You can add dependency comment from the row level actions.</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">MainDoc depends on doc01. MainDoc details page</span><img height="219px;" src="https://lh4.googleusercontent.com/YcU3kkarOLcEUgz_tdIFKLJU2acJiVBX19Oa523RRb6BOmWJibnab_LH5gg41-2tgfYpRb98xLSTlajMKdL_wYj11bxAExyGcnkND0FdmyNd2Yphj9dGH4P1" width="670px;" /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">If you see the doc01 document, related document you can see MainDoc is dependent on doc01</span><img height="367px;" src="https://lh5.googleusercontent.com/kfcV8rRH8pIOA7e5Nna6MFZyFIw6fV21wqyfa3GMNcuW8B5CNzsa93LEzIzb04wuB9qcehyaT4HRts1A9l514-fgLYfveCcPOkHEUCYt557NJNI1awc7uxT6" width="664px;" /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;"><u>API Navigations:</u></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">To get the depedent documents, we need to navigate through this link table. The service APIs are available in WTDocumentService class.</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<a href="http://host/webapp/wt/clients/library/api/wt/doc/WTDocumentService.html" style="text-decoration: none;"><span style="color: #1155cc; font-family: Arial; font-size: 15px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">http://host/webapp/wt/clients/library/api/wt/doc/WTDocumentService.html</span></a></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">The relevant methods are (Please refer JavaDoc for more details)</span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr">
<table style="border-collapse: collapse; border: none;"><colgroup></colgroup><tbody>
<tr style="height: 0px;"><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt; text-align: right;">
<span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> QueryResult</span></div>
</td><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">getDependsOnWTDocuments</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">(WTDocument document)</span><span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Return a QueryResult of WTDocuments that the given WTDocument is dependent on.</span></div>
</td></tr>
<tr style="height: 0px;"><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt; text-align: right;">
<span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> QueryResult</span></div>
</td><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">getDependsOnWTDocuments</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">(WTDocument document, boolean onlyOtherSides)</span><span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Return a QueryResult of WTDocuments that the given WTDocument is dependent on.</span></div>
</td></tr>
</tbody></table>
</div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
</b></div>
Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com2tag:blogger.com,1999:blog-32875296.post-35755095925013626732013-04-16T10:46:00.000+05:302013-12-06T16:31:16.914+05:30Windchill Document Usage Link<div dir="ltr" style="text-align: left;" trbidi="on">
<b id="internal-source-marker_0.3696306864731014" style="font-weight: normal;"></b><br />
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.3696306864731014" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">The WTDocumentUsageLink is an IteratedUsageLink between WTDocuments and WTDocumentMasters and used to create uses relationships between documents or document structure.</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.3696306864731014" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.3696306864731014" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;"><u>For example:</u></span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.3696306864731014" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Several documents can contain the same glossary or one document can be made up of several sub-documents.</span></b></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.3696306864731014" style="font-weight: normal;"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Documents should use this if a document is made up of subdocuments and the sub-documents can be reused by other documents, or need to be controlled separately.</span></b></div>
<b id="internal-source-marker_0.3696306864731014"><br /><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;"></span><span style="font-weight: normal;"><img height="247px;" src="https://lh3.googleusercontent.com/5CrdMMspCY7uMMqGqtP7ItwTE6UyOjC8BQhg2FS1bqLpSnhGXAwUjdWx0mnhU3F7L-FfQeK2IJNAc9wJPRCDe-jBSA2UFi-BBFErY1ZVBeUAFkfMvoFlquSf" width="286px;" /></span><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;"></span></b><br />
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.3696306864731014"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<b id="internal-source-marker_0.3696306864731014">
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">The main document is linked to the other document’s master objects. Here main document is linked to the WTDocumentMaster objects of document_1, document_2 and document_3.</span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">This means main document is always pointing to the latest copy of all linked document even they get new version or iteration.</span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;"><u>Model Diagram:</u></span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;"><u><br /></u></span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<img height="265px;" src="https://lh6.googleusercontent.com/ETTYrbRuwRgtl8xISzQndxta6YpIV3CQxmUtp7OeTbuawpFNTpG5LC8-FNWL_KsNTvWGTU3RalVc8DYatDXEId_LOOaOZU3RrdmWovwRuW0gz_yr2S2EGXMt" width="423px;" /><span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;"></span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.3696306864731014"></b></div>
<div dir="ltr" style="display: inline !important; font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<b id="internal-source-marker_0.3696306864731014"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></b></div>
<br />
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;"><u>JavaDoc:</u></span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">URL:</span><a href="http://host/webapp/wt/clients/library/api/wt/doc/WTDocumentUsageLink.html" style="text-decoration: none;"><span style="color: black; font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="color: #1155cc; font-family: Arial; font-size: 15px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">http://host/webapp/wt/clients/library/api/wt/doc/WTDocumentUsageLink.html</span></a></div>
<div style="font-weight: normal; text-align: left;">
<span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"><br /></span></div>
<div style="text-align: left;">
<span style="font-family: Arial; font-size: 13px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;">wt.doc</span><span style="font-family: Arial; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; vertical-align: baseline; white-space: pre-wrap;">Class WTDocumentUsageLink</span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">java.lang.Object</span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">wt.fc.WTObject</span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> <span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">wt.fc.ObjectToObjectLink</span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> <span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">wt.vc.struct.IteratedUsageLink</span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> <span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;">wt.doc.WTDocumentUsageLink</span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 16px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">public class </span><span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;">WTDocumentUsageLink</span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">extends IteratedUsageLink</span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">implements Externalizable</span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;"><u>UI Navigations:</u></span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">To see the usage documents, navigate to main document’s details page -> Structure -> Document Structure table</span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">To add the child documents, use ‘Add Documents’ row level action on parent document.</span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span><img height="283px;" src="https://lh3.googleusercontent.com/qemOY_JKoxS8YyKzLheqK9QEDpNrnNVsMqx4bZTvwqdsrVmK0Kz92az_o67c3Vg7lMQs1jfhs2OstRwksUE2SLg7EVzqEGJAHrX2w2e_YJS28xJALRP5gVx3" width="468px;" /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;"><u>API Navigations:</u></span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">To get the usage documents, we need to navigate through this link table. The service APIs are available in WTDocumentService class.</span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<a href="http://host/webapp/wt/clients/library/api/wt/doc/WTDocumentService.html" style="text-decoration: none;"><span style="color: #1155cc; font-family: Arial; font-size: 15px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">http://host/webapp/wt/clients/library/api/wt/doc/WTDocumentService.html</span></a></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="font-weight: normal; line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">The relevant methods are (Please refer JavaDoc for more details)</span></div>
<div dir="ltr" style="font-weight: normal;">
<table style="border-collapse: collapse; border: none;"><colgroup></colgroup><tbody>
<tr style="height: 0px;"><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt; text-align: right;">
<span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="color: #1155cc; font-family: Arial; font-size: 13px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">Enumeration</span></div>
</td><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="color: #1155cc; font-family: Arial; font-size: 13px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">getOrderedUsesWTDocumentMasters</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">(</span><span style="color: #1155cc; font-family: Arial; font-size: 13px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">WTDocument</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> document)</span><span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Navigates the WTDocumentUsageLink along the uses role, returning a Enumeration of WTDocumentMaster.</span></div>
</td></tr>
<tr style="height: 0px;"><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt; text-align: right;">
<span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="color: #1155cc; font-family: Arial; font-size: 13px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">Enumeration</span></div>
</td><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="color: #1155cc; font-family: Arial; font-size: 13px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">getOrderedUsesWTDocuments</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">(</span><span style="color: #1155cc; font-family: Arial; font-size: 13px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">WTDocument</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> document,</span><span style="font-family: 'Courier New'; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="color: #1155cc; font-family: Arial; font-size: 13px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">ConfigSpec</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> configSpec)</span><span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Applies the configSpec to the result of navigating the WTDocumentUsageLink along the uses role; returns a Enumeration of Persistable[], in which the WTDocumentUsageLinks are at the 0th position and the corresponding iterations (or master if there is no corresponding iteration) in the 1th position.</span></div>
</td></tr>
<tr style="height: 0px;"><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt; text-align: right;">
<span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="color: #1155cc; font-family: Arial; font-size: 13px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">QueryResult</span></div>
</td><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="color: #1155cc; font-family: Arial; font-size: 13px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">getUsedByWTDocuments</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">(</span><span style="color: #1155cc; font-family: Arial; font-size: 13px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">WTDocumentMaster</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> documentMaster)</span><span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Navigates the WTDocumentUsageLink along the usedBy role, returning a QueryResult of WTDocuments.</span></div>
</td></tr>
<tr style="height: 0px;"><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt; text-align: right;">
<span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="color: #1155cc; font-family: Arial; font-size: 13px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">QueryResult</span></div>
</td><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="color: #1155cc; font-family: Arial; font-size: 13px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">getUsesWTDocumentMasters</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">(</span><span style="color: #1155cc; font-family: Arial; font-size: 13px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">WTDocument</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> document)</span><span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Navigates the WTDocumentUsageLink along the uses role, returning a QueryResult of WTDocumentMaster.</span></div>
</td></tr>
<tr style="height: 0px;"><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt; text-align: right;">
<span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="color: #1155cc; font-family: Arial; font-size: 13px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">QueryResult</span></div>
</td><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="color: #1155cc; font-family: Arial; font-size: 13px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">getUsesWTDocuments</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">(</span><span style="color: #1155cc; font-family: Arial; font-size: 13px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">WTDocument</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> document,</span><span style="font-family: 'Courier New'; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="color: #1155cc; font-family: Arial; font-size: 13px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">WTDocumentConfigSpec</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> configSpec)</span><span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Applies the configSpec to the result of navigating the WTDocumentUsageLink along the uses role; returns a QueryResult of Persistable[], in which the WTDocumentUsageLinks are at the 0th position and the corresponding iterations (or master if there is no corresponding iteration) in the 1th position.</span></div>
</td></tr>
<tr style="height: 0px;"><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt; text-align: right;">
<span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="color: #1155cc; font-family: Arial; font-size: 13px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">QueryResult</span></div>
</td><td style="border: 1px solid rgb(0, 0, 0); padding: 3px; vertical-align: top;"><div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="color: #1155cc; font-family: Arial; font-size: 13px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">getUsesWTDocumentUsageLinks</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">(</span><span style="color: #1155cc; font-family: Arial; font-size: 13px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">WTDocument</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> document)</span><span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span style="font-family: Arial; font-size: 19px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Returns the WTDocumentUsageLinks resulting from navigating the WTDocumentUsageLink along the uses role.</span></div>
</td></tr>
</tbody></table>
</div>
</b></div>
Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com3tag:blogger.com,1999:blog-32875296.post-31719092270036961012013-04-15T14:53:00.000+05:302013-12-06T16:31:16.908+05:30Windchill Rose Web Publisher<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<div class="MsoNormal">
<span style="font-family: inherit;">While working on Windchill customization, sometimes we need
to look into the object models. In Windchill 9.1 we can use the Rational Rose
tool for the same but most of the times the tool is not available to all the
developers. In this scenario, we can use the Windchill Rose Web Publisher tool
to view the object model.<o:p></o:p></span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: inherit;">Access Windchill Rose Web Publisher using URL: <o:p></o:p></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><a href="http://host/webapp/wt/clients/library/model/root.html">http://host/webapp/wt/clients/library/model/root.html</a><o:p></o:p></span></div>
<div class="MsoNormal">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhZE5-YC0Tf_aq7Nk19uWMAJtKdZFUMxRihGCKp5m9J8XP_xlTOSybb8L6TWvf9u5tsOoSkxb8B_qGsYistTPyYnhQccxoRcvBQq9xUl4oi8wyVGjE2sg4uouVX9sjY89p-g_mT/s1600/RoseWebPublisher.png" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhZE5-YC0Tf_aq7Nk19uWMAJtKdZFUMxRihGCKp5m9J8XP_xlTOSybb8L6TWvf9u5tsOoSkxb8B_qGsYistTPyYnhQccxoRcvBQq9xUl4oi8wyVGjE2sg4uouVX9sjY89p-g_mT/s1600/RoseWebPublisher.png" height="321" width="640" /></a></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><br /></span></div>
<div class="MsoNormal">
<span style="font-family: inherit;">Navigate to Logical View -> Assembly -> Module ->
appropriate package and double click on item. Please find below screenshot for wt.doc
package object model</span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: inherit;"><u>Note: </u>There may be issue in panel scrolling. Try different
browsers. Mostly works with IE.</span><o:p></o:p></div>
</div>
Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com1tag:blogger.com,1999:blog-32875296.post-65283195567248629632013-04-12T11:00:00.000+05:302013-12-06T16:31:16.920+05:30Custom Util: CSV File Writer<div dir="ltr" style="text-align: left;" trbidi="on">
In many utilities or operations we want output to be in CSV file format. This is frequently used operation so it is always better to have util class which can handle all this CSV file writing.<br />
Posting CSV file writer util class along with a test class. Please share your thoughts to optimize this code.<br />
<br />
<u style="font-weight: bold;">CSV File Writer:</u><br />
<span class="kn" style="color: #007020; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px; font-weight: bold;">package</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">com</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">.</span><span class="na" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">blogspot</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">.</span><span class="na" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">maheshmhetre</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">.</span><span class="na" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">util</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">;</span><br />
<pre style="border: none; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px; overflow: auto; padding: 10px;"><span class="kn" style="color: #007020; font-weight: bold;">import</span> <span class="nn" style="color: #0e84b5; font-weight: bold;">java.io.File</span><span class="o" style="color: #666666;">;</span>
<span class="kn" style="color: #007020; font-weight: bold;">import</span> <span class="nn" style="color: #0e84b5; font-weight: bold;">java.io.FileWriter</span><span class="o" style="color: #666666;">;</span>
<span class="kn" style="color: #007020; font-weight: bold;">import</span> <span class="nn" style="color: #0e84b5; font-weight: bold;">java.io.IOException</span><span class="o" style="color: #666666;">;</span>
<span class="kn" style="color: #007020; font-weight: bold;">import</span> <span class="nn" style="color: #0e84b5; font-weight: bold;">java.text.DateFormat</span><span class="o" style="color: #666666;">;</span>
<span class="kn" style="color: #007020; font-weight: bold;">import</span> <span class="nn" style="color: #0e84b5; font-weight: bold;">java.text.SimpleDateFormat</span><span class="o" style="color: #666666;">;</span>
<span class="kn" style="color: #007020; font-weight: bold;">import</span> <span class="nn" style="color: #0e84b5; font-weight: bold;">java.util.Date</span><span class="o" style="color: #666666;">;</span>
<span class="cm" style="color: #60a0b0; font-style: italic;">/**</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> * Util class used for CSV file writing.</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> * @author mmhetre</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> *</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> */</span>
<span class="kd" style="color: #007020; font-weight: bold;">public</span> <span class="kd" style="color: #007020; font-weight: bold;">class</span> <span class="nc" style="color: #0e84b5; font-weight: bold;">CSVFileWriter</span> <span class="o" style="color: #666666;">{</span>
<span class="kd" style="color: #007020; font-weight: bold;">public</span> <span class="kd" style="color: #007020; font-weight: bold;">static</span> <span class="kd" style="color: #007020; font-weight: bold;">final</span> <span class="n">String</span> <span class="n">FILE_SEPARATOR</span> <span class="o" style="color: #666666;">=</span> <span class="n">System</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">getProperty</span><span class="o" style="color: #666666;">(</span><span class="s" style="color: #4070a0;">"file.separator"</span><span class="o" style="color: #666666;">);</span>
<span class="kd" style="color: #007020; font-weight: bold;">private</span> <span class="n">StringBuilder</span> <span class="n">outputStr</span> <span class="o" style="color: #666666;">=</span> <span class="kc" style="color: #007020; font-weight: bold;">null</span><span class="o" style="color: #666666;">;</span>
<span class="kd" style="color: #007020; font-weight: bold;">private</span> <span class="n">FileWriter</span> <span class="n">fw</span> <span class="o" style="color: #666666;">=</span> <span class="kc" style="color: #007020; font-weight: bold;">null</span><span class="o" style="color: #666666;">;</span>
<span class="kd" style="color: #007020; font-weight: bold;">private</span> <span class="n">String</span> <span class="n">csvFilePath</span> <span class="o" style="color: #666666;">=</span> <span class="s" style="color: #4070a0;">""</span><span class="o" style="color: #666666;">;</span>
<span class="cm" style="color: #60a0b0; font-style: italic;">/**</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> * Constructor.</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> * @param filePathWithoutFileName CSV file path without file name</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> * @param fileName File Name without file extension/type</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> * @param shouldAppendDateAndTime Should append timestamp to the file name? If true, the final file name </span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> * will be fileName_timestamp.csv else fileName.csv </span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> * @throws IOException</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> */</span>
<span class="kd" style="color: #007020; font-weight: bold;">public</span> <span class="nf" style="color: #06287e;">CSVFileWriter</span><span class="o" style="color: #666666;">(</span><span class="n">String</span> <span class="n">filePathWithoutFileName</span><span class="o" style="color: #666666;">,</span> <span class="n">String</span> <span class="n">fileName</span><span class="o" style="color: #666666;">,</span> <span class="kt" style="color: #902000;">boolean</span> <span class="n">shouldAppendDateAndTime</span><span class="o" style="color: #666666;">)</span>
<span class="kd" style="color: #007020; font-weight: bold;">throws</span> <span class="n">IOException</span><span class="o" style="color: #666666;">{</span>
<span class="k" style="color: #007020; font-weight: bold;">if</span><span class="o" style="color: #666666;">(</span><span class="n">shouldAppendDateAndTime</span><span class="o" style="color: #666666;">){</span>
<span class="n">DateFormat</span> <span class="n">dateFormate</span> <span class="o" style="color: #666666;">=</span> <span class="k" style="color: #007020; font-weight: bold;">new</span> <span class="n">SimpleDateFormat</span><span class="o" style="color: #666666;">(</span><span class="s" style="color: #4070a0;">"yyyy-MM-dd"</span><span class="o" style="color: #666666;">);</span>
<span class="n">String</span> <span class="n">date</span> <span class="o" style="color: #666666;">=</span> <span class="n">dateFormate</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">format</span><span class="o" style="color: #666666;">(</span><span class="k" style="color: #007020; font-weight: bold;">new</span> <span class="n">Date</span><span class="o" style="color: #666666;">());</span>
<span class="n">DateFormat</span> <span class="n">timeFormat</span> <span class="o" style="color: #666666;">=</span> <span class="k" style="color: #007020; font-weight: bold;">new</span> <span class="n">SimpleDateFormat</span><span class="o" style="color: #666666;">(</span><span class="s" style="color: #4070a0;">"hh-mm-ss"</span><span class="o" style="color: #666666;">);</span>
<span class="n">String</span> <span class="n">time</span> <span class="o" style="color: #666666;">=</span> <span class="n">timeFormat</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">format</span><span class="o" style="color: #666666;">(</span><span class="k" style="color: #007020; font-weight: bold;">new</span> <span class="n">Date</span><span class="o" style="color: #666666;">());</span>
<span class="n">csvFilePath</span> <span class="o" style="color: #666666;">=</span> <span class="n">filePathWithoutFileName</span> <span class="o" style="color: #666666;">+</span> <span class="n">FILE_SEPARATOR</span> <span class="o" style="color: #666666;">+</span> <span class="n">fileName</span> <span class="o" style="color: #666666;">+</span> <span class="s" style="color: #4070a0;">"_"</span> <span class="o" style="color: #666666;">+</span> <span class="n">date</span> <span class="o" style="color: #666666;">+</span> <span class="s" style="color: #4070a0;">"-"</span> <span class="o" style="color: #666666;">+</span> <span class="n">time</span> <span class="o" style="color: #666666;">+</span> <span class="s" style="color: #4070a0;">".csv"</span><span class="o" style="color: #666666;">;</span>
<span class="o" style="color: #666666;">}</span> <span class="k" style="color: #007020; font-weight: bold;">else</span> <span class="o" style="color: #666666;">{</span>
<span class="n">csvFilePath</span> <span class="o" style="color: #666666;">=</span> <span class="n">filePathWithoutFileName</span> <span class="o" style="color: #666666;">+</span> <span class="n">FILE_SEPARATOR</span> <span class="o" style="color: #666666;">+</span> <span class="n">fileName</span> <span class="o" style="color: #666666;">+</span> <span class="s" style="color: #4070a0;">".csv"</span><span class="o" style="color: #666666;">;</span>
<span class="o" style="color: #666666;">}</span>
<span class="n">fw</span> <span class="o" style="color: #666666;">=</span> <span class="n">createFileWriter</span><span class="o" style="color: #666666;">(</span><span class="n">csvFilePath</span><span class="o" style="color: #666666;">);</span>
<span class="n">outputStr</span> <span class="o" style="color: #666666;">=</span> <span class="k" style="color: #007020; font-weight: bold;">new</span> <span class="n">StringBuilder</span><span class="o" style="color: #666666;">();</span>
<span class="o" style="color: #666666;">}</span>
<span class="cm" style="color: #60a0b0; font-style: italic;">/**</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> * Add row in the CSV file.</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> * @param commaSeperatedStr Row data. The comma separated string.</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> */</span>
<span class="kd" style="color: #007020; font-weight: bold;">public</span> <span class="kt" style="color: #902000;">void</span> <span class="nf" style="color: #06287e;">addRow</span><span class="o" style="color: #666666;">(</span><span class="n">String</span> <span class="n">commaSeperatedStr</span><span class="o" style="color: #666666;">){</span>
<span class="k" style="color: #007020; font-weight: bold;">if</span> <span class="o" style="color: #666666;">(</span><span class="n">outputStr</span> <span class="o" style="color: #666666;">==</span> <span class="kc" style="color: #007020; font-weight: bold;">null</span><span class="o" style="color: #666666;">)</span>
<span class="n">outputStr</span> <span class="o" style="color: #666666;">=</span> <span class="k" style="color: #007020; font-weight: bold;">new</span> <span class="n">StringBuilder</span><span class="o" style="color: #666666;">();</span>
<span class="k" style="color: #007020; font-weight: bold;">if</span> <span class="o" style="color: #666666;">(</span><span class="n">csvFilePath</span> <span class="o" style="color: #666666;">==</span> <span class="kc" style="color: #007020; font-weight: bold;">null</span><span class="o" style="color: #666666;">)</span>
<span class="k" style="color: #007020; font-weight: bold;">return</span><span class="o" style="color: #666666;">;</span>
<span class="n">outputStr</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">append</span><span class="o" style="color: #666666;">(</span><span class="n">commaSeperatedStr</span><span class="o" style="color: #666666;">);</span>
<span class="n">outputStr</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">append</span><span class="o" style="color: #666666;">(</span><span class="s" style="color: #4070a0;">"\n"</span><span class="o" style="color: #666666;">);</span>
<span class="k" style="color: #007020; font-weight: bold;">if</span> <span class="o" style="color: #666666;">(</span><span class="n">outputStr</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">length</span><span class="o" style="color: #666666;">()</span> <span class="o" style="color: #666666;"><</span> <span class="mi" style="color: #40a070;">5000</span><span class="o" style="color: #666666;">)</span>
<span class="k" style="color: #007020; font-weight: bold;">return</span><span class="o" style="color: #666666;">;</span>
<span class="c1" style="color: #60a0b0; font-style: italic;">//if output string size more than 5000 flush to the file</span>
<span class="k" style="color: #007020; font-weight: bold;">try</span> <span class="o" style="color: #666666;">{</span>
<span class="n">fw</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">write</span><span class="o" style="color: #666666;">(</span><span class="n">outputStr</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">toString</span><span class="o" style="color: #666666;">().</span><span class="na" style="color: #4070a0;">toCharArray</span><span class="o" style="color: #666666;">());</span>
<span class="n">fw</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">flush</span><span class="o" style="color: #666666;">();</span>
<span class="n">outputStr</span> <span class="o" style="color: #666666;">=</span> <span class="k" style="color: #007020; font-weight: bold;">new</span> <span class="n">StringBuilder</span><span class="o" style="color: #666666;">();</span>
<span class="o" style="color: #666666;">}</span><span class="k" style="color: #007020; font-weight: bold;">catch</span> <span class="o" style="color: #666666;">(</span><span class="n">Exception</span> <span class="n">e</span><span class="o" style="color: #666666;">)</span> <span class="o" style="color: #666666;">{</span>
<span class="n">e</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">printStackTrace</span><span class="o" style="color: #666666;">();</span>
<span class="o" style="color: #666666;">}</span>
<span class="o" style="color: #666666;">}</span>
<span class="cm" style="color: #60a0b0; font-style: italic;">/**</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> * Stop file writing</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> */</span>
<span class="kd" style="color: #007020; font-weight: bold;">public</span> <span class="kt" style="color: #902000;">void</span> <span class="nf" style="color: #06287e;">stopFileWriting</span><span class="o" style="color: #666666;">(){</span>
<span class="k" style="color: #007020; font-weight: bold;">try</span> <span class="o" style="color: #666666;">{</span>
<span class="k" style="color: #007020; font-weight: bold;">if</span> <span class="o" style="color: #666666;">(</span><span class="n">outputStr</span> <span class="o" style="color: #666666;">!=</span> <span class="kc" style="color: #007020; font-weight: bold;">null</span><span class="o" style="color: #666666;">)</span> <span class="o" style="color: #666666;">{</span>
<span class="k" style="color: #007020; font-weight: bold;">if</span><span class="o" style="color: #666666;">(</span><span class="n">outputStr</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">toString</span><span class="o" style="color: #666666;">().</span><span class="na" style="color: #4070a0;">trim</span><span class="o" style="color: #666666;">().</span><span class="na" style="color: #4070a0;">length</span><span class="o" style="color: #666666;">()</span> <span class="o" style="color: #666666;">!=</span> <span class="mi" style="color: #40a070;">0</span><span class="o" style="color: #666666;">)</span> <span class="o" style="color: #666666;">{</span>
<span class="n">fw</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">write</span><span class="o" style="color: #666666;">(</span><span class="n">outputStr</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">toString</span><span class="o" style="color: #666666;">().</span><span class="na" style="color: #4070a0;">toCharArray</span><span class="o" style="color: #666666;">());</span>
<span class="o" style="color: #666666;">}</span>
<span class="n">fw</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">close</span><span class="o" style="color: #666666;">();</span>
<span class="n">fw</span> <span class="o" style="color: #666666;">=</span> <span class="kc" style="color: #007020; font-weight: bold;">null</span><span class="o" style="color: #666666;">;</span>
<span class="n">csvFilePath</span> <span class="o" style="color: #666666;">=</span> <span class="kc" style="color: #007020; font-weight: bold;">null</span><span class="o" style="color: #666666;">;</span>
<span class="n">outputStr</span> <span class="o" style="color: #666666;">=</span> <span class="kc" style="color: #007020; font-weight: bold;">null</span><span class="o" style="color: #666666;">;</span>
<span class="o" style="color: #666666;">}</span>
<span class="o" style="color: #666666;">}</span><span class="k" style="color: #007020; font-weight: bold;">catch</span> <span class="o" style="color: #666666;">(</span><span class="n">Exception</span> <span class="n">e</span><span class="o" style="color: #666666;">)</span> <span class="o" style="color: #666666;">{</span>
<span class="n">e</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">printStackTrace</span><span class="o" style="color: #666666;">();</span>
<span class="o" style="color: #666666;">}</span>
<span class="o" style="color: #666666;">}</span>
<span class="cm" style="color: #60a0b0; font-style: italic;">/**</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> * Get CVS file path</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> * @return</span>
<span class="cm" style="color: #60a0b0; font-style: italic;"> */</span>
<span class="kd" style="color: #007020; font-weight: bold;">public</span> <span class="n">String</span> <span class="nf" style="color: #06287e;">getCSVFilePath</span><span class="o" style="color: #666666;">(){</span>
<span class="k" style="color: #007020; font-weight: bold;">return</span> <span class="n">csvFilePath</span><span class="o" style="color: #666666;">;</span>
<span class="o" style="color: #666666;">}</span>
<span class="kd" style="color: #007020; font-weight: bold;">private</span> <span class="n">FileWriter</span> <span class="nf" style="color: #06287e;">createFileWriter</span><span class="o" style="color: #666666;">(</span><span class="n">String</span> <span class="n">fileName</span><span class="o" style="color: #666666;">)</span> <span class="kd" style="color: #007020; font-weight: bold;">throws</span> <span class="n">IOException</span><span class="o" style="color: #666666;">{</span>
<span class="n">File</span> <span class="n">aFile</span> <span class="o" style="color: #666666;">=</span> <span class="k" style="color: #007020; font-weight: bold;">new</span> <span class="n">File</span><span class="o" style="color: #666666;">(</span><span class="n">fileName</span><span class="o" style="color: #666666;">);</span>
<span class="n">FileWriter</span> <span class="n">fw</span> <span class="o" style="color: #666666;">=</span> <span class="k" style="color: #007020; font-weight: bold;">new</span> <span class="n">FileWriter</span><span class="o" style="color: #666666;">(</span><span class="n">aFile</span><span class="o" style="color: #666666;">,</span> <span class="kc" style="color: #007020; font-weight: bold;">true</span><span class="o" style="color: #666666;">);</span>
<span class="k" style="color: #007020; font-weight: bold;">return</span> <span class="n">fw</span><span class="o" style="color: #666666;">;</span>
<span class="o" style="color: #666666;">}</span>
<span class="o" style="color: #666666;">}</span></pre>
<b><u>CSV File Writing Test Class:</u></b><br />
<span class="kn" style="color: #007020; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px; font-weight: bold;">package</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">com</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">.</span><span class="na" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">blogspot</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">.</span><span class="na" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">maheshmhetre</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">.</span><span class="na" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">util</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">;</span><br />
<pre style="border: none; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px; overflow: auto; padding: 10px;"><span class="kn" style="color: #007020; font-weight: bold;">import</span> <span class="nn" style="color: #0e84b5; font-weight: bold;">java.io.IOException</span><span class="o" style="color: #666666;">;</span>
<span class="kn" style="color: #007020; font-weight: bold;">import</span> <span class="nn" style="color: #0e84b5; font-weight: bold;">wt.util.WTException</span><span class="o" style="color: #666666;">;</span>
<span class="kd" style="color: #007020; font-weight: bold;">public</span> <span class="kd" style="color: #007020; font-weight: bold;">class</span> <span class="nc" style="color: #0e84b5; font-weight: bold;">TestCSVFileWriter</span> <span class="o" style="color: #666666;">{</span>
<span class="kd" style="color: #007020; font-weight: bold;">private</span> <span class="kd" style="color: #007020; font-weight: bold;">static</span> <span class="kd" style="color: #007020; font-weight: bold;">final</span> <span class="kt" style="color: #902000;">char</span> <span class="n">COMMA_SEPERATOR</span> <span class="o" style="color: #666666;">=</span> <span class="sc" style="color: #4070a0;">','</span><span class="o" style="color: #666666;">;</span>
<span class="kd" style="color: #007020; font-weight: bold;">private</span> <span class="kd" style="color: #007020; font-weight: bold;">static</span> <span class="n">String</span> <span class="n">CSV_FILE_DIR</span> <span class="o" style="color: #666666;">=</span> <span class="n">System</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">getProperty</span><span class="o" style="color: #666666;">(</span><span class="s" style="color: #4070a0;">"user.dir"</span><span class="o" style="color: #666666;">);</span>
<span class="kd" style="color: #007020; font-weight: bold;">private</span> <span class="n">CSVFileWriter</span> <span class="n">csvFileWriter</span> <span class="o" style="color: #666666;">=</span> <span class="kc" style="color: #007020; font-weight: bold;">null</span><span class="o" style="color: #666666;">;</span>
<span class="kd" style="color: #007020; font-weight: bold;">public</span> <span class="kd" style="color: #007020; font-weight: bold;">static</span> <span class="kt" style="color: #902000;">void</span> <span class="nf" style="color: #06287e;">main</span><span class="o" style="color: #666666;">(</span><span class="n">String</span><span class="o" style="color: #666666;">[]</span> <span class="n">args</span><span class="o" style="color: #666666;">)</span> <span class="o" style="color: #666666;">{</span>
<span class="n">TestCSVFileWriter</span> <span class="n">fileWritingTest</span> <span class="o" style="color: #666666;">=</span> <span class="k" style="color: #007020; font-weight: bold;">new</span> <span class="n">TestCSVFileWriter</span><span class="o" style="color: #666666;">();</span>
<span class="k" style="color: #007020; font-weight: bold;">try</span> <span class="o" style="color: #666666;">{</span>
<span class="k" style="color: #007020; font-weight: bold;">for</span> <span class="o" style="color: #666666;">(</span><span class="kt" style="color: #902000;">int</span> <span class="n">i</span> <span class="o" style="color: #666666;">=</span> <span class="mi" style="color: #40a070;">0</span><span class="o" style="color: #666666;">;</span> <span class="n">i</span> <span class="o" style="color: #666666;"><</span> <span class="mi" style="color: #40a070;">10</span><span class="o" style="color: #666666;">;</span> <span class="n">i</span><span class="o" style="color: #666666;">++)</span> <span class="o" style="color: #666666;">{</span>
<span class="c1" style="color: #60a0b0; font-style: italic;">//adding random cell data. Add actual data here</span>
<span class="n">fileWritingTest</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">addRowToOutputCSVFile</span><span class="o" style="color: #666666;">(</span><span class="n">i</span> <span class="o" style="color: #666666;">+</span> <span class="s" style="color: #4070a0;">"qq"</span><span class="o" style="color: #666666;">,</span> <span class="n">i</span> <span class="o" style="color: #666666;">+</span> <span class="mi" style="color: #40a070;">2</span> <span class="o" style="color: #666666;">+</span> <span class="s" style="color: #4070a0;">"tt"</span><span class="o" style="color: #666666;">,</span> <span class="n">i</span> <span class="o" style="color: #666666;">+</span> <span class="mi" style="color: #40a070;">5</span> <span class="o" style="color: #666666;">+</span> <span class="s" style="color: #4070a0;">"zz"</span><span class="o" style="color: #666666;">);</span>
<span class="o" style="color: #666666;">}</span>
<span class="o" style="color: #666666;">}</span> <span class="k" style="color: #007020; font-weight: bold;">catch</span> <span class="o" style="color: #666666;">(</span><span class="n">Exception</span> <span class="n">e</span><span class="o" style="color: #666666;">)</span> <span class="o" style="color: #666666;">{</span>
<span class="n">e</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">printStackTrace</span><span class="o" style="color: #666666;">();</span>
<span class="o" style="color: #666666;">}</span> <span class="k" style="color: #007020; font-weight: bold;">finally</span> <span class="o" style="color: #666666;">{</span>
<span class="k" style="color: #007020; font-weight: bold;">if</span> <span class="o" style="color: #666666;">(</span><span class="n">fileWritingTest</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">csvFileWriter</span> <span class="o" style="color: #666666;">!=</span> <span class="kc" style="color: #007020; font-weight: bold;">null</span><span class="o" style="color: #666666;">)</span> <span class="o" style="color: #666666;">{</span>
<span class="n">fileWritingTest</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">csvFileWriter</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">stopFileWriting</span><span class="o" style="color: #666666;">();</span>
<span class="o" style="color: #666666;">}</span>
<span class="o" style="color: #666666;">}</span>
<span class="o" style="color: #666666;">}</span>
<pre style="border: none; font-family: 'Bitstream Vera Sans Mono', monospace; overflow: auto; padding: 10px;"><span class="c1" style="color: #60a0b0; font-style: italic;">//Change method signature according to your output CSV file format</span></pre>
<pre style="border: none; font-family: 'Bitstream Vera Sans Mono', monospace; overflow: auto; padding: 10px;"><span class="kd" style="color: #007020; font-weight: bold;">private</span> <span class="kt" style="color: #902000;">void</span> <span class="nf" style="color: #06287e;">addRowToOutputCSVFile</span><span class="o" style="color: #666666;">(</span><span class="n">String</span> <span class="n">cellOne</span><span class="o" style="color: #666666;">,</span> <span class="n">String</span> <span class="n">cellTwo</span><span class="o" style="color: #666666;">, </span><span class="n">String</span> <span class="n">cellThree</span><span class="o" style="color: #666666;">)</span> <span class="kd" style="color: #007020; font-weight: bold;">throws</span> <span class="n">WTException</span><span class="o" style="color: #666666;">{</span></pre>
<pre style="border: none; font-family: 'Bitstream Vera Sans Mono', monospace; overflow: auto; padding: 10px;"><span style="color: #60a0b0; font-style: italic;">//Create output CSV file if not available</span></pre>
<span class="k" style="color: #007020; font-weight: bold;">try</span> <span class="o" style="color: #666666;">{</span>
<span class="k" style="color: #007020; font-weight: bold;">if</span><span class="o" style="color: #666666;">(</span><span class="n">csvFileWriter</span> <span class="o" style="color: #666666;">==</span> <span class="kc" style="color: #007020; font-weight: bold;">null</span><span class="o" style="color: #666666;">){</span>
<span class="c1" style="color: #60a0b0; font-style: italic;">//pass your desired file dir</span>
<span class="n">csvFileWriter</span> <span class="o" style="color: #666666;">=</span> <span class="k" style="color: #007020; font-weight: bold;">new</span> <span class="n">CSVFileWriter</span><span class="o" style="color: #666666;">(</span><span class="n">CSV_FILE_DIR</span><span class="o" style="color: #666666;">,</span> <span class="s" style="color: #4070a0;">"MyCSVFile"</span><span class="o" style="color: #666666;">,</span> <span class="kc" style="color: #007020; font-weight: bold;">true</span><span class="o" style="color: #666666;">);</span>
<span class="o" style="color: #666666;">}</span>
<span class="o" style="color: #666666;">}</span> <span class="k" style="color: #007020; font-weight: bold;">catch</span> <span class="o" style="color: #666666;">(</span><span class="n">IOException</span> <span class="n">e</span><span class="o" style="color: #666666;">)</span> <span class="o" style="color: #666666;">{</span>
<span class="k" style="color: #007020; font-weight: bold;">throw</span> <span class="k" style="color: #007020; font-weight: bold;">new</span> <span class="nf" style="color: #06287e;">WTException</span><span class="o" style="color: #666666;">(</span><span class="s" style="color: #4070a0;">"Error while creating CSV File. "</span> <span class="o" style="color: #666666;">+</span> <span class="n">e</span><span class="o" style="color: #666666;">);</span>
<span class="o" style="color: #666666;">}</span>
<span class="k" style="color: #007020; font-weight: bold;">try</span> <span class="o" style="color: #666666;">{</span>
<span class="n">csvFileWriter</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">addRow</span><span class="o" style="color: #666666;">(</span><span class="n">cellOne</span>
<span class="o" style="color: #666666;">+</span> <span class="n">COMMA_SEPERATOR</span> <span class="o" style="color: #666666;">+</span> <span class="n">cellTwo</span>
<span class="o" style="color: #666666;">+</span> <span class="n">COMMA_SEPERATOR</span> <span class="o" style="color: #666666;">+</span> <span class="n">cellThree</span><span class="o" style="color: #666666;">);</span>
<span class="o" style="color: #666666;">}</span> <span class="k" style="color: #007020; font-weight: bold;">catch</span> <span class="o" style="color: #666666;">(</span><span class="n">Exception</span> <span class="n">e</span><span class="o" style="color: #666666;">)</span> <span class="o" style="color: #666666;">{</span>
<span class="k" style="color: #007020; font-weight: bold;">throw</span> <span class="k" style="color: #007020; font-weight: bold;">new</span> <span class="nf" style="color: #06287e;">WTException</span><span class="o" style="color: #666666;">(</span><span class="n">e</span><span class="o" style="color: #666666;">);</span>
<span class="o" style="color: #666666;">}</span>
<span class="o" style="color: #666666;">}</span>
<span class="o" style="color: #666666;">}</span></pre>
<pre style="border: none; font-size: 13px; overflow: auto; padding: 10px;"><span class="o" style="color: #666666;"><span style="font-family: Arial, Helvetica, sans-serif;">You can download code here:</span><span style="font-family: Bitstream Vera Sans Mono, monospace;"> </span><a href="https://docs.google.com/file/d/0B4lAe-Ay9iqvU2RIRVVxU21pX2M/edit?usp=sharing&pli=1" style="font-family: 'Bitstream Vera Sans Mono', monospace;">CSVFileWriter</a><span style="font-family: Bitstream Vera Sans Mono, monospace;"> </span><a href="https://docs.google.com/file/d/0B4lAe-Ay9iqvMU5PRTd3Y1h5aHc/edit?usp=sharing" style="font-family: 'Bitstream Vera Sans Mono', monospace;">TestCSVFileWriter</a></span></pre>
</div>
Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com0tag:blogger.com,1999:blog-32875296.post-55672792409423661772013-04-10T15:34:00.000+05:302013-12-06T16:31:16.917+05:30Windchill Stickiness <div dir="ltr" style="text-align: left;" trbidi="on">
<b id="internal-source-marker_0.7220073551870883"></b><br />
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span id="internal-source-marker_0.7220073551870883"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">While working on Windchill 9.1, many times we come across situations where the first and second level navigation (tabs) are not appropriate and pointing to unexpected tab selections. Also some times on login by a user, the user is navigating to a URL all the times even you tried to change the URL like users are not able to access tabs because the stickiness context is wrong.</span></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span id="internal-source-marker_0.7220073551870883"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Examples: Clicking on Library tab leads to the Product tab.</span></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span id="internal-source-marker_0.7220073551870883"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span id="internal-source-marker_0.7220073551870883"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">This is because of stickiness in the Windchill. Such issues can be resolved by clearing the stickiness.</span></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span id="internal-source-marker_0.7220073551870883"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"> </span></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span id="internal-source-marker_0.7220073551870883"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"><b>How to clear stickiness?</b></span></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span id="internal-source-marker_0.7220073551870883"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">1.</span><span style="font-family: Arial; font-size: 9px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Go to below UR</span></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt; text-indent: 36pt;">
<span id="internal-source-marker_0.7220073551870883"><a href="about:blank" style="text-decoration: none;"><span style="color: #1155cc; font-family: Arial; font-size: 15px; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">http://machine/webApp/netmarkets/jsp/components/stickiness.jsp</span></a></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span id="internal-source-marker_0.7220073551870883"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">2.</span><span style="font-family: Arial; font-size: 9px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">The page will show you</span></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt; text-indent: 36pt;">
<span id="internal-source-marker_0.7220073551870883"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">a.</span><span style="font-family: Arial; font-size: 9px; vertical-align: baseline; white-space: pre-wrap;"> <span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Clear sticky info for all tabs</span></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt; text-indent: 36pt;">
<span id="internal-source-marker_0.7220073551870883"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">b.</span><span style="font-family: Arial; font-size: 9px; vertical-align: baseline; white-space: pre-wrap;"> <span class="Apple-tab-span" style="white-space: pre;"> </span></span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">All first level navigation tab names with the link to clear respective stickiness</span><img height="274px;" src="https://lh4.googleusercontent.com/qg-c5sJL6nhRUSMoCyt20PuGpNHTZy91QzlwfhRYvyMo9vcozCNy_xLJYhI6PdCb28UvNOPKKxzG3Mhu-LBdnDnDZ3UtTO5zOONygxG7vfYlygjs_IndA3kZMQ" width="311px;" /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span id="internal-source-marker_0.7220073551870883"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">3.</span><span style="font-family: Arial; font-size: 9px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">Now you can clear all tabs stickiness or tab based by clicking on the relevant links</span></span></div>
<div dir="ltr" style="line-height: 1.15; margin-bottom: 0pt; margin-top: 0pt;">
<span id="internal-source-marker_0.7220073551870883"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">4.</span><span style="font-family: Arial; font-size: 9px; vertical-align: baseline; white-space: pre-wrap;"> </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">To ensure that all client stickiness is removed, delete all your temporary internet files (usually in the Tools menu), close all browser windows, and restart the browser.</span></span></div>
</div>
Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com1tag:blogger.com,1999:blog-32875296.post-76263910358601057272013-03-19T20:27:00.004+05:302013-12-06T16:31:16.931+05:30Windchill Command Line Utility Skeleton<span style="font-family: inherit;">In the last topic <a href="http://maheshmhetre.blogspot.in/2013/03/windchill-remote-method-server-access.html">Windchill Remote Method Server Access API</a> we saw how we can use RemoteMethodServer to invoke method server code remotely. Even though there are plenty of utilities available in Windchill OOTB, we came across various scenarios where we need to write our own custom utilities.</span><br />
<span style="font-family: inherit;">In this post I am trying to share the Windchill command line utility skeleton which uses RemoteMethodServer.</span><br />
<pre style="border: none; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px; overflow: auto; padding: 10px;"><span class="kn" style="color: #007020; font-weight: bold;">package</span> <span class="n">com</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">blogspot</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">maheshmhetre</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">windchill</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">utilities</span><span class="o" style="color: #666666;">;</span>
<span class="kn" style="color: #007020; font-weight: bold;">import</span> <span class="nn" style="color: #0e84b5; font-weight: bold;">java.lang.reflect.InvocationTargetException</span><span class="o" style="color: #666666;">;</span>
<span class="kn" style="color: #007020; font-weight: bold;">import</span> <span class="nn" style="color: #0e84b5; font-weight: bold;">java.rmi.RemoteException</span><span class="o" style="color: #666666;">;</span>
<span class="kn" style="color: #007020; font-weight: bold;">import</span> <span class="nn" style="color: #0e84b5; font-weight: bold;">wt.method.RemoteAccess</span><span class="o" style="color: #666666;">;</span>
<span class="kn" style="color: #007020; font-weight: bold;">import</span> <span class="nn" style="color: #0e84b5; font-weight: bold;">wt.method.RemoteMethodServer</span><span class="o" style="color: #666666;">;</span>
<span class="kn" style="color: #007020; font-weight: bold;">import</span> <span class="nn" style="color: #0e84b5; font-weight: bold;">wt.session.SessionHelper</span><span class="o" style="color: #666666;">;</span>
<span class="kn" style="color: #007020; font-weight: bold;">import</span> <span class="nn" style="color: #0e84b5; font-weight: bold;">wt.util.WTException</span><span class="o" style="color: #666666;">;</span>
<span class="kd" style="color: #007020; font-weight: bold;">public</span> <span class="kd" style="color: #007020; font-weight: bold;">class</span> <span class="nc" style="color: #0e84b5; font-weight: bold;">WindchillCustomUtilitySkeleton</span> <span class="o" style="color: #666666;">{</span>
<span class="c1" style="color: #60a0b0; font-style: italic;">//START of inner class - Server</span>
<span class="kd" style="color: #007020; font-weight: bold;">public</span> <span class="kd" style="color: #007020; font-weight: bold;">static</span> <span class="kd" style="color: #007020; font-weight: bold;">class</span> <span class="nc" style="color: #0e84b5; font-weight: bold;">Server</span> <span class="kd" style="color: #007020; font-weight: bold;">implements</span> <span class="n">RemoteAccess</span> <span class="o" style="color: #666666;">{</span>
<span class="kd" style="color: #007020; font-weight: bold;">public</span> <span class="kd" style="color: #007020; font-weight: bold;">static</span> <span class="kt" style="color: #902000;">void</span> <span class="nf" style="color: #06287e;">methodOne</span><span class="o" style="color: #666666;">(</span><span class="n">String</span> <span class="n">param1</span><span class="o" style="color: #666666;">,</span> <span class="n">String</span> <span class="n">param2</span><span class="o" style="color: #666666;">)</span> <span class="o" style="color: #666666;">{</span>
<span class="k" style="color: #007020; font-weight: bold;">try</span> <span class="o" style="color: #666666;">{</span>
<span class="c1" style="color: #60a0b0; font-style: italic;">//Get login credentials</span>
<span class="n">SessionHelper</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">manager</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">getPrincipal</span><span class="o" style="color: #666666;">();</span>
<span class="c1" style="color: #60a0b0; font-style: italic;">//Call core processing method</span>
<span class="n">WindchillCustomUtilitySkeleton</span> <span class="n">utility</span> <span class="o" style="color: #666666;">=</span> <span class="k" style="color: #007020; font-weight: bold;">new</span> <span class="n">WindchillCustomUtilitySkeleton</span><span class="o" style="color: #666666;">();</span>
<span class="n">utility</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">doOperation</span><span class="o" style="color: #666666;">(</span><span class="n">param1</span><span class="o" style="color: #666666;">,</span> <span class="n">param2</span><span class="o" style="color: #666666;">);</span>
<span class="o" style="color: #666666;">}</span> <span class="k" style="color: #007020; font-weight: bold;">catch</span> <span class="o" style="color: #666666;">(</span><span class="n">Exception</span> <span class="n">e</span><span class="o" style="color: #666666;">)</span> <span class="o" style="color: #666666;">{</span>
<span class="n">e</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">printStackTrace</span><span class="o" style="color: #666666;">();</span>
<span class="o" style="color: #666666;">}</span>
<span class="k" style="color: #007020; font-weight: bold;">return</span><span class="o" style="color: #666666;">;</span>
<span class="o" style="color: #666666;">}</span>
<span class="o" style="color: #666666;">}</span> <span class="c1" style="color: #60a0b0; font-style: italic;">//END of inner class - Server</span>
<span class="kd" style="color: #007020; font-weight: bold;">private</span> <span class="kt" style="color: #902000;">void</span> <span class="nf" style="color: #06287e;">doOperation</span><span class="o" style="color: #666666;">(</span><span class="n">String</span> <span class="n">param1</span><span class="o" style="color: #666666;">,</span> <span class="n">String</span> <span class="n">param2</span><span class="o" style="color: #666666;">)</span> <span class="kd" style="color: #007020; font-weight: bold;">throws</span> <span class="n">WTException</span><span class="o" style="color: #666666;">{</span>
<span class="c1" style="color: #60a0b0; font-style: italic;">//TODO execute your utility logic</span>
<span class="n">System</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">out</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">println</span><span class="o" style="color: #666666;">(</span><span class="s" style="color: #4070a0;">"This sysout will be available in method server log."</span><span class="o" style="color: #666666;">);</span>
<span class="o" style="color: #666666;">}</span>
<span class="kd" style="color: #007020; font-weight: bold;">public</span> <span class="kd" style="color: #007020; font-weight: bold;">static</span> <span class="kt" style="color: #902000;">void</span> <span class="nf" style="color: #06287e;">main</span><span class="o" style="color: #666666;">(</span><span class="n">String</span><span class="o" style="color: #666666;">[]</span> <span class="n">args</span><span class="o" style="color: #666666;">)</span> <span class="o" style="color: #666666;">{</span>
<span class="c1" style="color: #60a0b0; font-style: italic;">//TODO get utility input parameters</span>
<span class="c1" style="color: #60a0b0; font-style: italic;">//TODO basic validation</span>
<span class="n">System</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">out</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">println</span><span class="o" style="color: #666666;">(</span><span class="s" style="color: #4070a0;">"This sysout will be available on console from where the utility is running."</span><span class="o" style="color: #666666;">);</span>
<span class="c1" style="color: #60a0b0; font-style: italic;">//prepare input params</span>
<span class="c1" style="color: #60a0b0; font-style: italic;">//data types will depends on your method parameters and can be any valid object type</span>
<span class="n">Class</span> <span class="n">argTypes</span><span class="o" style="color: #666666;">[]</span> <span class="o" style="color: #666666;">=</span> <span class="o" style="color: #666666;">{</span><span class="n">String</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">class</span><span class="o" style="color: #666666;">,</span> <span class="n">String</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">class</span><span class="o" style="color: #666666;">};</span><span class="c1" style="color: #60a0b0; font-style: italic;">//add all remote method parameter data types</span>
<span class="n">Object</span> <span class="n">argValues</span><span class="o" style="color: #666666;">[]</span> <span class="o" style="color: #666666;">=</span> <span class="o" style="color: #666666;">{</span><span class="s" style="color: #4070a0;">"param_1_value"</span><span class="o" style="color: #666666;">,</span> <span class="s" style="color: #4070a0;">"param_2_value"</span><span class="o" style="color: #666666;">};</span><span class="c1" style="color: #60a0b0; font-style: italic;">//respective data value</span>
<span class="c1" style="color: #60a0b0; font-style: italic;">//call remote method - pass inner class name, method name, arg types and arg values</span>
<span class="k" style="color: #007020; font-weight: bold;">try</span> <span class="o" style="color: #666666;">{</span>
<span class="n">RemoteMethodServer</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">getDefault</span><span class="o" style="color: #666666;">().</span><span class="na" style="color: #4070a0;">invoke</span><span class="o" style="color: #666666;">(</span><span class="s" style="color: #4070a0;">"methodOne"</span><span class="o" style="color: #666666;">,</span>
<span class="s" style="color: #4070a0;">"com.blogspot.maheshmhetre.windchill.utilities.WindchillCustomUtilitySkeleton$Server"</span><span class="o" style="color: #666666;">,</span>
<span class="kc" style="color: #007020; font-weight: bold;">null</span><span class="o" style="color: #666666;">,</span> <span class="n">argTypes</span><span class="o" style="color: #666666;">,</span> <span class="n">argValues</span><span class="o" style="color: #666666;">);</span>
<span class="o" style="color: #666666;">}</span> <span class="k" style="color: #007020; font-weight: bold;">catch</span> <span class="o" style="color: #666666;">(</span><span class="n">RemoteException</span> <span class="n">e</span><span class="o" style="color: #666666;">)</span> <span class="o" style="color: #666666;">{</span>
<span class="n">e</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">printStackTrace</span><span class="o" style="color: #666666;">();</span>
<span class="o" style="color: #666666;">}</span> <span class="k" style="color: #007020; font-weight: bold;">catch</span> <span class="o" style="color: #666666;">(</span><span class="n">InvocationTargetException</span> <span class="n">e</span><span class="o" style="color: #666666;">)</span> <span class="o" style="color: #666666;">{</span>
<span class="n">e</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">printStackTrace</span><span class="o" style="color: #666666;">();</span>
<span class="o" style="color: #666666;">}</span>
<span class="n">Runtime</span><span class="o" style="color: #666666;">.</span><span class="na" style="color: #4070a0;">getRuntime</span><span class="o" style="color: #666666;">().</span><span class="na" style="color: #4070a0;">exit</span><span class="o" style="color: #666666;">(</span><span class="mi" style="color: #40a070;">0</span><span class="o" style="color: #666666;">);</span>
<span class="o" style="color: #666666;">}</span>
<span class="o" style="color: #666666;">}</span></pre>
<br />
<span style="font-family: inherit;">Please share your thoughts to improve this skeleton.</span>Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com2tag:blogger.com,1999:blog-32875296.post-32020537365358989072013-03-19T18:11:00.004+05:302013-12-06T16:31:16.911+05:30Windchill Remote Method Server Access API<br />
<div class="MsoNormal">
To invoke Windchill server side code from outside method
server, we need to use RMI calls. Windchill provides mechanism to do this by
using RemoteMethodServer class.<o:p></o:p></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
The method signature</div>
<div class="MsoNormal">
<span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">RemoteMethodServer</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">.</span><span class="na" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">getDefault</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">().</span><span class="na" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">invoke</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">(</span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">String</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">methodName</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">,</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">String</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">className</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">,</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">Object</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">obj</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">,</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">Class</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">[]</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">paramClassTypeArray</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">,</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">Objet</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">[]</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">paramValuesArray</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">);</span></div>
<div class="MsoNormal">
<span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"><br /></span></div>
<div class="MsoNormal">
</div>
<div class="MsoNormal">
The core code to invoke remote method is</div>
<div class="MsoNormal">
<span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">RemoteMethodServer</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">remotemethodserver</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">=</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">RemoteMethodServer</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">.</span><span class="na" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">getDefault</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">();</span></div>
<div class="MsoNormal">
<span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">remotemethodserver</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">.</span><span class="na" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">setUserName</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">(</span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">userName</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">);</span></div>
<div class="MsoNormal">
<span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">remotemethodserver</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">.</span><span class="na" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">setPassword</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">(</span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">Password</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">);</span></div>
<div class="MsoNormal">
<span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"><br /></span></div>
<div class="MsoNormal">
<span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">Class</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">argTypes</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">[]</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">=</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">{</span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">String</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">.</span><span class="na" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">class</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">,</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">String</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">.</span><span class="na" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">class</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">};</span><span class="c1" style="color: #60a0b0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px; font-style: italic;">//add all remote method parameter data types</span></div>
<div class="MsoNormal">
<span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">Object</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">argValues</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">[]</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">=</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">{</span><span class="s" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">"param_1_value"</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">,</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="s" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">"param_2_value"</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">};</span><span class="c1" style="color: #60a0b0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px; font-style: italic;">//respective data value</span></div>
<div class="MsoNormal">
<span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"><br /></span></div>
<div class="MsoNormal">
<span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">Object</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">returnObj</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">=</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">remotemethodserver</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">.</span><span class="na" style="color: #4070a0; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">invoke</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">(</span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">methodName</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">,</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">className</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">,</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="kc" style="color: #007020; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px; font-weight: bold;">null</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">,</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">argTypes</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">,</span><span style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;"> </span><span class="n" style="font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">argValues</span><span class="o" style="color: #666666; font-family: 'Bitstream Vera Sans Mono', monospace; font-size: 13px;">);</span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
</div>
<div class="MsoNormal">
If you want the user who is executing the code should
provide username and password explicitly using basic authentication handled by
framework, skip the username and password set to RemoteMethodServer and user SessionHelper.manager.getPrincipal();
Adding this will give popup for username and password if not available. <o:p></o:p></div>
<div class="MsoNormal">
Keep in mind that there may be an issue if you are executing
the remote access code from some external terminal like putty session. The
popup will not work by default and need some additional settings.<br />
<br />
<o:p></o:p></div>
<div class="MsoNormal">
</div>
<div class="MsoNormal">
In the next post we will see a <u>command line utility skeleton</u> which uses
RemoteMethodServer API.</div>
Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com9tag:blogger.com,1999:blog-32875296.post-7906392183098607282013-03-12T09:35:00.000+05:302013-12-06T16:31:16.936+05:30How package names to be formed?<div dir="ltr" style="text-align: left;" trbidi="on">
<div>
Many times I came across Java developers who are not clear how the package names to be formed. Here I am trying to explain on how package names to be formed.<br />
<br /></div>
<div>
Generally package name start with reverse domain name resolution and later the application and module name and then finally the area you are working</div>
<div>
</div>
<div>
The package name can be formed as below<br />
<TLD>.<org/domain name>.<application name>.<module name>.<sub-module name>.<working area>.<more down level if needed><br />
<br />
Consider below is the scenario</div>
<div>
<ul style="text-align: left;">
<li>Organization domain name: www.myOrg.com</li>
<li>Application Name: Windchill</li>
<li>Module Name: Lifecycle</li>
<li>Sub Module Name: Assignment</li>
<li>Working Area: Participants</li>
</ul>
</div>
<div>
Following the above pattern my package name will be</div>
<div>
<i>com.myorg.windchill.lifecycle.assignment.participants</i></div>
<div>
<br />
I always try emphasis on the deep level or extended package name so that the package will have only specific/relevant classes available. Please try to avoid putting many class in a single package and try to put them into very specific package.<br />
<br />
Hope this is a useful information. </div>
</div>
Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com0tag:blogger.com,1999:blog-32875296.post-26237576111506776702013-03-09T19:54:00.001+05:302013-12-06T16:31:16.898+05:30Windchill OOTB Utility - "Which"<div dir="ltr" style="text-align: left;" trbidi="on">
<b id="internal-source-marker_0.6606323574669659" style="font-weight: normal;"><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">While working on Windchill customization, I came across a scenario where want know the class location but no idea where that class resides. I tried to find in eclipse as well but no luck as I can’t add all Windchill jars in the eclipse. </span><br /><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">In this case I can use the Windchill OOTB utility “Which” to lookup the class/file path in the Windchill.</span><br /><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">This utility lookups all the occurrences of the provided file in the classpath which includes the jars files as well.</span><br /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span><br /><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">This is a command line utility. The command is as below</span><br /><span style="font-family: Arial; font-size: 13px; font-style: italic; vertical-align: baseline; white-space: pre-wrap;">windchill wt.util.jmx.Which <resourcename></resourcename></span></b><br />
<b style="font-weight: normal;"><span style="font-family: Arial; font-size: x-small;"><span style="white-space: pre-wrap;"><i><br /></i></span></span><span style="font-family: Arial; font-size: 13px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">Utility usage:</span></b><br />
<b style="font-weight: normal;"><img height="284px;" src="https://lh5.googleusercontent.com/l_0DowYO7dJT_mChCOO6b6BO9u5lS38V92VIMVayCKWknE4yPf0AOw_NE95ym8_n4iXIE3jSjWlLKPEtZ1ZLc0SIPjr12WgYJ_9-CnxNJJLGzUVpLXXpSKwA" width="623px;" /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span><br /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"></span></b><b style="font-weight: normal;"><span style="font-family: Arial; font-size: 13px; font-weight: bold; text-decoration: underline; vertical-align: baseline; white-space: pre-wrap;">Example:</span></b><br />
<b style="font-weight: normal;"><img height="220px;" src="https://lh3.googleusercontent.com/geq__UjH77W8yuIocX1QrMbRm8D6kLfNKsNISEfLPkFmZJqsQOgWNGTY9EyQAViGC8mmIdgj7Qrz84Ak8uI_Z5RRe7Sdqmc1hQ2Pf3v1M7tx9zDxUKrdgpwz" width="624px;" /></b><b style="font-weight: normal;"><br /><br /><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">Running the above command, we get a result says the class file present in /</span><span style="font-family: Arial; font-size: 13px; font-style: italic; vertical-align: baseline; white-space: pre-wrap;">Windchill_9.1/Windchill/codebase/WEB-INF/lib/wncWeb.jar</span><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;"> file.</span><br /><span style="font-family: Arial; font-size: 13px; vertical-align: baseline; white-space: pre-wrap;">If the same file present at multiple location, then we utility returns all possible locations of the file.</span></b></div>
Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com2tag:blogger.com,1999:blog-32875296.post-73300752508811757312013-03-09T09:31:00.000+05:302013-12-06T16:31:16.928+05:30Windchill-Eclipse : Hot Code Replace<b id="internal-source-marker_0.20155081525444984"><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;">In the previous posts <a href="http://maheshmhetre.blogspot.in/2013/02/windchill-eclipse-project-setup_19.html">Windchill-Eclipse Project Setup</a> and <a href="http://maheshmhetre.blogspot.in/2013/02/windchill-method-server-debugging.html">Windchill Method Server Debugging</a> we discussed the basic Windchill development setup. Now it’s time to speed up the development. In this post we are going to add “Hot Code Replace” functionality in our Windchill development environment. The is the real development nitro booster.</span><br /><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;"></span><br /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"><u>What is hot code replace?</u><span style="font-weight: normal;"> – Ref: eclipse.org</span></span><br /><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;">Hot code replace (HCR) is a debugging technique whereby the Eclipse Java debugger transmits new class files over the debugging channel to another JVM. In the case of Eclipse development, this also applies to the VM that runs the runtime workbench. The idea is that you can start a debugging session on a given runtime workbench and change a Java file in your development workbench, and the debugger will replace the code in the receiving VM while it is running. No restart is required, hence the reference to "hot". </span><br /><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;"></span><br /><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;">In our Windchill development environment setup, we are going to add eclipse project workspace into Windchill classpath. So when you will start eclipse method server debugging and in between debugging mode if you modify any class, the updated class code will get execute and most importantly without class compile or method server restart. </span><br /><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;">So we saved a lot time in sysouts, class compilation and method server restart</span><br /><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;"></span><br /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"><u>Add hot code replace in Windchill development environment setup:</u></span></b><br />
<ol style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="font-family: Arial; font-size: 15px; list-style-type: decimal; vertical-align: baseline;"><b id="internal-source-marker_0.20155081525444984" style="font-weight: normal;"><span style="vertical-align: baseline; white-space: pre-wrap;">Take backup of <i><windchill_home>/codebase/wt.properties.xconf</windchill_home></i></span></b></li>
<li dir="ltr" style="font-family: Arial; font-size: 15px; list-style-type: decimal; vertical-align: baseline;"><b id="internal-source-marker_0.20155081525444984" style="font-weight: normal;"><span style="vertical-align: baseline; white-space: pre-wrap;">In <i><windchill_home>/codebase/wt.properties.xconf</windchill_home></i> edit "<i>wt.java.classpath</i>" property value to add eclipse project workspace path. In the property value you need to add your eclipse project workspace bin folder path.</span></b></li>
</ol>
<b id="internal-source-marker_0.20155081525444984"><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"><span class="Apple-tab-span" style="font-weight: normal; white-space: pre;"> </span>e.g.</span><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;"> My eclipse project workspace bin folder path is <i>/opt/eclipseworkspace/Windchill/bin</i>. Replace the directory separator by Windchill directory separator variable </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">$(dir.sep)</span><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;">. Now my updated path will be <i>$(dir.sep)opt$(dir.sep)eclipseworkspace$(dir.sep)Windchill$(dir.sep)bin</i>. Add this value in the beginning of property value with the Windchill classpath separator variable </span><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;">$(path.sep)</span><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;">.</span><br /><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;">The updated property value will be <u>like</u> as below (<i><eclipse bin="" folder="" path="" project="" workspace="">$(path.sep)<original property="" value=""></original></eclipse></i>)</span><br /><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;"></span><br /><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;">Property name="wt.java.classpath" multivalued="$(path.sep)" default="<span style="background-color: yellow;">$(dir.sep)opt$(dir.sep)eclipseworkspace$(dir.sep)Windchill$(dir.sep)bin$(path.sep)</span>$(wt.home)$(dir.sep)codebase$(path.sep)$LIB(wt.webinf.lib)$(path.sep) --- and original</span><br /><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;"></span></b><br />
<ol start="3" style="margin-bottom: 0pt; margin-top: 0pt;"><span id="internal-source-marker_0.20155081525444984">
<li dir="ltr" style="font-family: Arial; font-size: 15px; list-style-type: decimal; vertical-align: baseline;"><span style="vertical-align: baseline; white-space: pre-wrap;">Run xconfmanager utility to propagate the xconf value </span></li>
<li dir="ltr" style="font-family: Arial; font-size: 15px; list-style-type: decimal; vertical-align: baseline;"><span style="vertical-align: baseline; white-space: pre-wrap;">Restart method server</span></li>
</span></ol>
<b id="internal-source-marker_0.20155081525444984">
<span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;"></span><br /><span style="font-family: Arial; font-size: 15px; vertical-align: baseline; white-space: pre-wrap;"><u>Note:</u></span></b><br />
<ol style="font-weight: normal; margin-bottom: 0pt; margin-top: 0pt;"><b id="internal-source-marker_0.20155081525444984">
<li dir="ltr" style="font-family: Arial; font-size: 15px; list-style-type: decimal; vertical-align: baseline;"><span style="vertical-align: baseline; white-space: pre-wrap;">Works in eclipse debug mode only</span></li>
<li dir="ltr" style="font-family: Arial; font-size: 15px; list-style-type: decimal; vertical-align: baseline;"><span style="vertical-align: baseline; white-space: pre-wrap;">Make sure that Project -> Build Automatically is checked (enabled)</span></li>
<li dir="ltr" style="font-family: Arial; font-size: 15px; list-style-type: decimal; vertical-align: baseline;"><span style="vertical-align: baseline; white-space: pre-wrap;">Hot code replace works effectively for method level code changes but some time fails for class level changes like adding method/variable, imports, etc</span></li>
</b></ol>
<b id="internal-source-marker_0.20155081525444984">
<span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;"></span><br /><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;">Now start Windchill development without sysouts and method server restarts. So shift the development gear and go bhuuuummmmmmmm</span><br /><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;"></span><br /><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;">To know more about hot code replace visit <a href="http://wiki.eclipse.org/FAQ_What_is_hot_code_replace%3F">http://wiki.eclipse.org/FAQ_What_is_hot_code_replace%3F</a></span></b><br />
<ol>
</ol>
<div>
<b><span style="font-family: Arial; font-size: 15px; font-weight: normal; vertical-align: baseline; white-space: pre-wrap;"><br /></span></b></div>
Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com0tag:blogger.com,1999:blog-32875296.post-26594394474777947272013-02-25T12:56:00.000+05:302013-12-06T16:31:16.901+05:30Windchill Method Server Debugging<span id="internal-source-marker_0.9761461604245059" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">In the last topic <a href="http://maheshmhetre.blogspot.in/2013/02/windchill-eclipse-project-setup_19.html">Windchill-Eclipse Project Setup</a> we discussed how to setup a Windchill development environment setup in Eclipse.</span><br />
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Now
we are adding one more thing in our development environment which will
help in debugging Windchill method server in eclipse. Below settings are
specific to Windchill 9.1 release.</span><br />
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span><br />
<ol style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Set method server running port</span></li>
</ol>
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"> Take backup of </span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: italic; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"><windchill_home>/codebase/wt.properties.xconf</windchill_home></span><br />
<div dir="ltr" style="margin-bottom: 0pt; margin-left: 36pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">In </span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: italic; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"><windchill_home>/codebase/wt.properties.xconf</windchill_home></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"> edit below property to add method server port and java memory allocations</span></div>
<div dir="ltr" style="margin-bottom: 0pt; margin-left: 36pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: italic; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></div>
<div dir="ltr" style="margin-bottom: 0pt; margin-left: 36pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: italic; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">name="wt.manager.cmd.MethodServer.platform.java.args"
default="$(wt.manager.cmd.MethodServer.nonibm.java.args)" </span></div>
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: italic; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span><br />
<div dir="ltr" style="margin-bottom: 0pt; margin-top: 0pt; text-indent: 36pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">This property pointing to different property again so ultimately we need change</span></div>
<div dir="ltr" style="margin-bottom: 0pt; margin-left: 36pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: italic; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">name="wt.manager.cmd.MethodServer.nonibm.java.args" default="-XX:PermSize=72m -XX:MaxPermSize=200m"</span></div>
<div dir="ltr" style="margin-bottom: 0pt; margin-top: 0pt; text-indent: 36pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: italic; font-variant: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;">Note:</span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"> The “default” value can be different in your environment.</span></div>
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span><br />
<div dir="ltr" style="margin-bottom: 0pt; margin-top: 0pt; text-indent: 36pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Change the default value as highlighted below</span></div>
<div dir="ltr" style="margin-bottom: 0pt; margin-left: 36pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: italic; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">name="wt.manager.cmd.MethodServer.nonibm.java.args" default=</span><span style="background-color: white;"><span style="color: black; font-family: Arial; font-size: 15px; font-style: italic; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"><span style="color: black; font-family: Arial; font-size: 15px; font-style: italic; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">"<b>-XX</b></span></span><b><span style="color: black; font-family: Arial; font-size: 15px; font-style: italic; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"><b>:PermSize=72m</b>
<b>-XX:MaxPermSize=200m -Xdebug -Xnoagent -Xrunjdwp:transport=dt_socket,
server=y, suspend=n, address=7777 -Djava.compiler=NONE</b></span></b></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: italic; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"><span style="background-color: white;">"</span> </span></div>
<ol start="2" style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Run xconfmanager utility</span></li>
</ol>
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"> Run xconfmanager utility to propagate the xconf value</span><br />
<ol start="3" style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Restart method server</span></li>
</ol>
<div dir="ltr" style="margin-bottom: 0pt; margin-left: 36pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Once you restart the method server, the method server will start running on port (7777) specified in the property above.</span></div>
<div dir="ltr" style="margin-bottom: 0pt; margin-left: 36pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Note:
You can check the method server running port in the method server logs.
The very first line will show the method server running port.</span></div>
<ol start="4" style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Eclipse debugging setup</span></li>
<ol style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: lower-alpha; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Click on Debug -> Debug configurations</span></li>
</ol>
</ol>
<div dir="ltr" style="margin-bottom: 0pt; margin-left: 36pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"> </span><img height="258px;" src="https://lh6.googleusercontent.com/3dKRcSNSGOuPpvfrgLiTSK0fxCqN0nEHF3HipGcECoR4XvRv7do8idEputajL98iGqwy_wjn6UAhQ3qTVH2vZpLshkipZtf-krEkCLQBFgEAd9GGBpKLjAPH" width="356px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></div>
<ol start="2" style="margin-bottom: 0pt; margin-top: 0pt;"><ol start="2" style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: lower-alpha; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Navigate to “Remote Java Application” -> “New”</span><img height="197px;" src="https://lh3.googleusercontent.com/EvlD8aYP7om1Qt4YkI8Sum8QrwdP7z22X8Xw06xc41J6HBaLY6zTbNmR7iAIP2AQ4wMMrrWcUrXdjQiolm0cZFjYVYSjHc_0hw7oIAV1rTll6MN0p1kCycKK" width="578px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: lower-alpha; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Provide Name, Host and Port. Click on “Apply”.</span><img height="297px;" src="https://lh5.googleusercontent.com/hXVE713clLC-tpkm8bPpbbOHCEbbk-dd7fAwOhf1m4NqVsjGOailTvgzkVtdNE1pDpVFNQf0uew-bbQ2kbyIULDedvuLtuVl2uuDSTvDMSnt7A8iTjAHk2dJ" width="581px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: lower-alpha; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Click on “Debug”.</span></li>
</ol>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">If all the properties and setting specified are correct, you will see the eclipse started in debug mode (</span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: italic; font-variant: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;">Note:</span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"> Method server must be up and running)</span><img height="218px;" src="https://lh5.googleusercontent.com/XT7sS9FHEgU-2vlufab_u4NLAFrpZVbixUyAdndTaf1ex4W6YPEO0n7eGHApJ7A85OGMTR5D9wfI1ecmO-e38ef5OAm9sxKT3EjNdOTOQ9rS_rdni3b4WTtE" width="628px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Later
on you can start method server debugging from Debug drop down directly
by selecting your newly created “Remote Java Application” under “Debug”</span></li>
</ol>
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"> </span><img height="229px;" src="https://lh6.googleusercontent.com/fYyQmce99W9TzgigoOHrRBe_ace35RdOwlWYJd-On2-SbVOJkLZ1NwZ0tZca0lOeydGWv1ZQjhpSKaCrs1jcwtJCHctOl82Itid-SB_TMqaDS0ijyRCUQqwK" width="410px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span><br />
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span><br />
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Now you can do Windchill method server debugging as normal as Java project in eclipse.</span>Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com8tag:blogger.com,1999:blog-32875296.post-29440346787184831312013-02-19T17:05:00.001+05:302013-12-06T16:31:16.905+05:30Windchill-Eclipse Project Setup<ul id="internal-source-marker_0.25703576478044954" style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Open eclipse and select appropriate workspace</span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Create new Java project</span></li>
<ul style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Go to File -> New -> Project</span><img height="254px;" src="https://lh5.googleusercontent.com/HBq6MnI4H2v4Drk0yywFit3-TUAo9yCqHNZYkvCbPcWDKYky9euDbi0h5yIr2iSDSlKkoDCdeIrlcgmAJvuunxJAn7UvMuw0OhTUFpVzfSRlTc6R-NwWTm3O" width="598px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Select “Java Project” and click on Next</span><img height="505px;" src="https://lh6.googleusercontent.com/I1FxHO6c5oe9eaSp3dAXaOwh3yo6r-4L0g72jdUPgDeuiz_Pwo-Oc8hWqItx_Y1xS4De99qmF2-u-NJDpPpfySaA_GoxmEPPP7Rc_WCWZzRPqRxuq37V-2KC" width="528px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Enter project name. Select appropriate JDK version depends on the Windchill version you are working on. Click on Finish.</span><img height="578px;" src="https://lh5.googleusercontent.com/imCQK8gLoI1cNIu-8AORPMCulDQKrFXRs8La5Dy07Z6zQowkhG6tWxh1kEY7xdZDK3W00YJH14PbPl-Gt-yqu02sW2ZWYeLqOnbsP6GDhjjOj7jPgBNU6L9e" width="560px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">The project is created with src folder</span><img height="239px;" src="https://lh4.googleusercontent.com/Kp6T3WMcY2L4kqkS0DUJN6SPGjJ-hDCeDrFweabcDQiRZmpiguHEr6veoilhIZ3A3EbGGyhq08eAbMu-KAU7IxkwdgX6whh8VpM-9coNNw9p4ZgwSUfI3nCh" width="390px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
</ul>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Right click on project and click on Properties.</span></li>
<ul style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Note:
Navigating to project Properties needed many times. The shortcut is
select project and use “Alt + Enter”. This will navigate you to directly
project properties.</span><img height="667px;" src="https://lh6.googleusercontent.com/J7Vy5N6j_SUdF1Usw7d7ClHWvonEhuycgXTFdTI5x1bsjmMPzUBm9ABp6hfwDK4tpDg1Wl3ulyXTbwD5NxcvWmsnRzRQBFMH3yRIeXZfDgbjiw6A-Cm40TeV" width="471px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
</ul>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Navigate to Java Compiler -> Building -> Output folder</span></li>
<ul style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Uncheck the “Scrub output folders when cleaning projects” and click on OK</span><img height="438px;" src="https://lh6.googleusercontent.com/GO3UxGXnBoZ08Kt0YGJliQ0BnK1y1wYYKl9df4NH2pRj2tEaAwWMBxiXbgVpWXM4YHUkU2hZn2jJ6-0aFb4U5vkHuX-8Zxyh6X2oq3GdmGXcbxdITa21A8Kc" width="628px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
</ul>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Click on Yes. This will rebuild the project to take the building setting in effect.</span><img height="354px;" src="https://lh5.googleusercontent.com/4DQPwaR0XpX1K9ji9iXMZkKJNz5XMujoYi4zgkc-cS5o3OHi8jtOVOk4QywLk6zxWzFWzaHMWWN7z-osQsKjLwoKjrx8E2F2d7EfTHhKczgR_G8fajn5UB_F" width="628px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Add OOTB Windchill JARs and codebase folder in project workspace</span></li>
<ul style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Navigate to project properties.</span><img height="272px;" src="https://lh6.googleusercontent.com/u39DsPAFWIKra8Q0HC0xcDXV1MKOIXMgMIYzS7OWAQjC6pJ0b5mCZl_wz5votEnICaAdKMdJK7FUebsIr99UOh_6dX2EJl1FkJvir7POarzjd7h7EUibRQLu" width="599px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
</ul>
</ul>
<br />
<div dir="ltr" style="margin-bottom: 0pt; margin-left: 72pt; margin-top: 0pt;">
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Hope you used shortcut (Alt + Enter) to navigate to project properties</span></div>
<br />
<ul style="margin-bottom: 0pt; margin-top: 0pt;"><ul style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Navigate to Java Build Path -> Libraries</span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Click
on “Add External Jars”. This will open a new selection window. Navigate
to Windchill_Home/lib and select all available libraries in this folder
and click OK.</span><img height="441px;" src="https://lh4.googleusercontent.com/zN3ZXU4-LJkJaSVcY-w8xtxJ3oAnvE1eYmazANk_T7tgGDjdJLzdaKoKQpfYDWOsGkM3iboYNJFEI-keHbDwNECpSBTXwotnHxnkd0LUSGMo3WuVkvlA8Jfe" width="599px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Click
on “Add External Jars”. This will open a new selection window. Navigate
to Windchill_Home/codevase/lib and select all available libraries in
this folder and click OK.</span><img height="444px;" src="https://lh6.googleusercontent.com/PtHk2ZMj7GxoQ7dkzaKk7gyK-Lu65cX6-h9PLwFZoJQYdoOFOKBqmHi_1hvv74qtivJ4Ui1OjMshhXH-A41KMUlx3aP7rgm-AOZCwBIbdyLWiQjC-Tl02l9x" width="599px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Click
on “Add External Jars”. This will open a new selection window. Navigate
to Windchill_Home/codebase/WEB-INF/lib and select all available
libraries in this folder and click OK.</span><img height="432px;" src="https://lh5.googleusercontent.com/J1-TButTkX8vQ16B6nqUQpeNFo-l4_6CXPium2nDWOV7vffETtwQJeu4qLgGA7x4Mfey_tKVmV3sNi6hnyGU5aKKmxtGhz8WcjkTHQjLoXUhtRReDLZw6aEh" width="599px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Click on “Add Class Folder”</span><img height="271px;" src="https://lh6.googleusercontent.com/jNmt-lWAL6rgK5IGg_3fWV1DSgydx9CmBU_h5mN9rdOVQhSBVhBwDI-3Zt670fyJXj9tkw92CowfCo4nkyjXbGLas3BRHUr5B71MYJhaESQXtZZC-5I2c85F" width="599px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Click on “Create New Folder”</span><img height="295px;" src="https://lh5.googleusercontent.com/EeXY2dk5JD-jBKbG3mJVyAVCjGDoo7QHnRhBSA1nC6NHmDzLJ1zRDxCBJLu8SPzY9T6GMzAp1pXoXY9P0YvBZJZz1l9kl6gFJLduSlOyvgEWChaIzVDpwh03" width="422px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Click on “Advanced”</span><img height="267px;" src="https://lh5.googleusercontent.com/pQ1lwPp7Af6x51It8eoUNR0zoYZ9ClgNAdGHv9TEBomvCq61Yipt_eYTeq877By7TPFyTK8CvNZ27DEd1WY00oDhIgNuhjM6AloIh34MjLxvLL1GULd3wFTO" width="508px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Select the checkbox – “Link to folder in the file system”. Click on “Browse”.</span><img height="314px;" src="https://lh3.googleusercontent.com/N0kvF1icsVZGvVS6Dy-rVcHvx3OAcgMbV_XWsS-ilq8LWZLtIPDJN-DtnhQ3b5oAe9HVCAzeAitMJXsWC5wGY2Xj4Du0BGWdqbliHMc9iEVSCIHtfqIfAM74" width="462px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Navigate to Windchill_Home and select “codebase”</span><img height="234px;" src="https://lh6.googleusercontent.com/aj3b3Wls0pglF2CUHn01hPOfquhGwOzCZLA_TJ-MWBaZjIcKUJD-gtyAqSffxe3rKtDG7i52dpxZ9NDxARWFplDFabN8-YIySzmJFHudsN6lCO_x3kmqweh1" width="600px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Click OK. This will take some time to add the codebase into project workspace.</span><img height="322px;" src="https://lh6.googleusercontent.com/2CuONCyWehbtmuzqptSmQ2Jaj8JOaiGknMd2SAgTUiZPcTRwZ-2E8xp0fgwN3gpcFu1QoA5j2GLc8LuAZK2dGbM7kV1AfiuoUDhRTXNuo6IMkQ95M7J344Na" width="458px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Verify that codebase folder is checked and click OK.</span><img height="358px;" src="https://lh6.googleusercontent.com/TrsNKBhIZn3UAKxiBP3mdMYF-ZhltqItTzG-9IacdGqXMAzoxhvjZ9wJV3MjUaH34aLLBhKOFpeM5H75CwwCDOI56N-HyIKgDpeNNVxp01SxrYRyUl0q_I4b" width="424px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
</ul>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Setting build and class load orders</span></li>
<ul style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Select “Order and Export”</span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Select codebase folder and click on “Top”</span><img height="445px;" src="https://lh5.googleusercontent.com/2ciQ9VyGDuvcTj5553v3_rGUPtiQOamTWFHZdaq0kc9pz817TqktpmfPeYlFBg6p9kF7dTrOPQKBXewfPmWUDF4_dsNvngp3_nRhSlvf30kIcSX_D37ZRgPy" width="598px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Use Up/Down key to set the build order. All the source folders should have higher build order than codebase folder.</span><img height="238px;" src="https://lh6.googleusercontent.com/VICcTlm_FDbOrwuxumHdUVCSOUyGkx9STkUwiAqRc1W3vMyHs6B0kiFAciG1WRqmwkNBUmsoC6GAG-G3xW6eaQfEYFfBJINQ7UrWRajwVejISOhXAUbuVeLp" width="598px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: circle; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Verify and click OK</span><img height="257px;" src="https://lh5.googleusercontent.com/6VX5bKLYJpurILKtCe6gXXtxAB_okj0Xj9mpe-TCYdLosRnm7rzcLRvA9zZWxpikr0RazZe_nemjaqrN9hIiOfZWrJ0q7YU2U0DbqbIHmsLH_YL8jntpMNT3" width="600px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
</ul>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Final project will look as below</span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span><img height="286px;" src="https://lh3.googleusercontent.com/QfABoMdXixtpQtY6xK-LGvaOK0KnmrkJSibrPEUrCTzF0pJvnJNHKjFgZ_FYkZYtLnNx6smbeOlM9vq3vo0tJ3ER_JWgYejdO90ZoQ2Itg7nCNqurbA8CuGP" width="388px;" /> </span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
</ul>
<br />
<ul style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Navigate to Project menu and verify that the “Build Automatically” is checked. If not then check.</span><img height="288px;" src="https://lh3.googleusercontent.com/vQTOxXiYkqonEqjyJ7NaSIIxX7SYpkDm1aph_NUMigx9jke5EgX0QeQzZoNJahsiYEDb1PZjNv2aVcD6pZ8dprXCavQGQVKOnyrQAdKODlTyQRbI3Kc8SUVW" width="628px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
</ul>
<br />
<span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">The Windchill eclipse project setup is done. Now you are set to browse the files available in workspace. E.g.</span><br />
<ul style="margin-bottom: 0pt; margin-top: 0pt;">
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Browse (Ctrl + Shift + R) jsp files</span><img height="192px;" src="https://lh5.googleusercontent.com/9bQWz8XI85d0_yLz01cyCkMQBxIibVAI_RUJbzfrXeTIp2Pg349XmZAOIaPsjeZEDFAV7bioIPmNxYWObBcArOB01NdhEnvp0ocrDFCf3JVDJIiv8l1Eo231" width="628px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
<li dir="ltr" style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;">Browse(Ctrl + Shift + R) properties files</span><img height="190px;" src="https://lh5.googleusercontent.com/NUMcvMMSHQjJNtQY0Sc0BITEsfOTCw7ZumUzkMsLaSl9lMuAnlIKPIcjkc0sNevzNmaGc9Pa5pcinm1UUusuwE3BRL3VYhivvZXkog-VMHpbS-Dy7F5F_fsM" width="628px;" /><span style="background-color: transparent; color: black; font-family: Arial; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"></span></li>
</ul>
<br />
<br />
<span style="font-family: Arial;">Next topic: Windchill-Eclipse method server debugging</span>Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com19tag:blogger.com,1999:blog-32875296.post-69414434666673820152013-02-18T17:27:00.003+05:302013-12-06T16:31:16.925+05:30Windchill ... Where to Start?Many guys who want or have to work on Windchill, the first question they usually ask is “Where to start?”.<br />
<br />
The best training material for Windchill is PTC University courses. This is a web based training provided by PTC and need to be purchased. <br />
<br />
As we can see, most of the companies working in Windchill are service industries. Rare to see those companies purchasing PTC University courses to train employees. Adding to this, these days the Windchill service industry following the pattern of hiring pure Java developers for Windchill customization and train them the Windchill framework. So all the responsibility goes to the senior person in the team who is most of time busy. <br />
Now you are at dead end where we must start to explore Windchill yourself. Here are few pointers where we can start learning Windchill.<br />
<br />
<b>Windchill Help:</b><br />
URL: <a href="http://hostname/Windchill-WHC/index.jspx">http://hostname/Windchill-WHC/index.jspx</a><br />
This the real material to learn the Windchill functionality. You can directly go to the home page and explore the area the you of interest. The other way is open help from the screen you are working on, this will take to the respective help topic.<br />
<br />
<b>Windchill Java/API Doc:</b><br />
Folder: Windchill_Home/codebase/wt/clients/library/api/index.html<br />
Web: <a href="http://hostname/Windchill/wt/clients/library/api/">http://hostname/Windchill/wt/clients/library/api/index.html</a><br />
<br />
<b>Windchill Examples:</b><br />
Location: Windchill_Home/codebase/netmarkets/jsp/carambola/customization/examples/<br />
Many examples found under his location.<br />
In Windchill 10.x you can found this under Tools as well.<br />
<br />
<b>Top most Windchill Guides:</b><br />
Windchill Customization Guide<br />
Windchill Business Administration Guide<br />
Windchill System Administration Guide<br />
<br />
<br />Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com6tag:blogger.com,1999:blog-32875296.post-76551064366582193282013-02-18T15:40:00.001+05:302013-12-06T16:31:16.933+05:30Resolution – ‘The Blogging’.Hello All,<br />
<br />
After a long time I am back to this page, feeling good.<br />
<br />
It may be New Year, Christmas, Diwali or any special occasion, almost everybody decides some good to do in the year which we called as a ‘Year Resolution’. Even I am not escaped from this :) <br />
<br />
So on my this birthday I opt a resolution – ‘The Blogging’.<br />
<br />
As I am PLM professional/consultant, I decided to go with one special blogging topic which is ‘PTC Windchill’. Along with this topic, will add blogs on Java and non-technical as well. While sharing my knowledge, this will really help me to improve my skills as well.<br />
<br />
Your love and support will keep me motivated to blog more and more.<br />
<br />
Let’s go …Mahesh Mhetrehttp://www.blogger.com/profile/13454367645029533896noreply@blogger.com2