package Savage.HarborEquipment.Buoys;

import org.web3d.x3d.jsail.Core.*;
import org.web3d.x3d.jsail.fields.*;
import org.web3d.x3d.jsail.Geometry3D.*;
import org.web3d.x3d.jsail.Grouping.*;
import org.web3d.x3d.jsail.Rendering.*;
import org.web3d.x3d.jsail.Shape.*;
import org.web3d.x3d.jsail.Texturing.*;

// Javadoc metadata annotations follow, see below for X3DJSAIL Java source code.
/**
 * <p> Marker Buoy. </p>
 <p> Related links: Catalog page <a href="../../../../HarborEquipment/Buoys/MarkerBuoyIndex.html" target="_blank">MarkerBuoy</a>,  source <a href="../../../../HarborEquipment/Buoys/MarkerBuoy.java">MarkerBuoy.java</a>, <a href="https://www.web3d.org/x3d/content/examples/X3dResources.html" target="_blank">X3D Resources</a>, <a href="https://www.web3d.org/x3d/content/examples/X3dSceneAuthoringHints.html" target="_blank">X3D Scene Authoring Hints</a>, and <a href="https://www.web3d.org/x3d/content/X3dTooltips.html" target="_blank">X3D Tooltips</a>. </p>
	<table style="color:black; border:0px solid; border-spacing:10px 0px;">
        <caption>Scene Meta Information</caption>
		<tr style="background-color:silver; border-color:silver;">
			<td style="text-align:center; padding:10px 0px;"><i>meta tags</i></td>
			<td style="text-align:left;   padding:10px 0px;">&nbsp; Document Metadata </td>
		</tr>

		<tr>
			<td style="text-align:right; vertical-align: text-top;"> <i> title </i> </td>
			<td> <a href="../../../../HarborEquipment/Buoys/MarkerBuoy.x3d">MarkerBuoy.x3d</a> </td>
		</tr>
		<tr>
			<td style="text-align:right; vertical-align: text-top;"> <i> description </i> </td>
			<td> Marker Buoy </td>
		</tr>
		<tr>
			<td style="text-align:right; vertical-align: text-top;"> <i> creator </i> </td>
			<td> Planet 9 Studios, Inc., San Francisco, CA </td>
		</tr>
		<tr>
			<td style="text-align:right; vertical-align: text-top;"> <i> producer </i> </td>
			<td> Christian Greuel, Director of Art and Production </td>
		</tr>
		<tr>
			<td style="text-align:right; vertical-align: text-top;"> <i> modelers </i> </td>
			<td> Danny Lee, Christian Greuel </td>
		</tr>
		<tr>
			<td style="text-align:right; vertical-align: text-top;"> <i> reference </i> </td>
			<td> <a href="http://www.planet9.com" target="_blank">http://www.planet9.com</a> </td>
		</tr>
		<tr>
			<td style="text-align:right; vertical-align: text-top;"> <i> translator </i> </td>
			<td> Xj3D Format Converter </td>
		</tr>
		<tr>
			<td style="text-align:right; vertical-align: text-top;"> <i> created </i> </td>
			<td> 17 August 2006 </td>
		</tr>
		<tr>
			<td style="text-align:right; vertical-align: text-top;"> <i> translated </i> </td>
			<td> 18 August 2006 </td>
		</tr>
		<tr>
			<td style="text-align:right; vertical-align: text-top;"> <i> modified </i> </td>
			<td> 20 October 2019 </td>
		</tr>
		<tr>
			<td style="text-align:right; vertical-align: text-top;"> <i> identifier </i> </td>
			<td> <a href="https://www.web3d.org/x3d/content/examples/Savage/HarborEquipment/Buoys/MarkerBuoy.x3d" target="_blank">https://www.web3d.org/x3d/content/examples/Savage/HarborEquipment/Buoys/MarkerBuoy.x3d</a> </td>
		</tr>
		<tr>
			<td style="text-align:right; vertical-align: text-top;"> <i> generator </i> </td>
			<td> X3D-Edit, <a href="https://www.web3d.org/x3d/tools/X3D-Edit" target="_blank">https://www.web3d.org/x3d/tools/X3D-Edit</a> </td>
		</tr>
		<tr>
			<td style="text-align:right; vertical-align: text-top;"> <i> license </i> </td>
			<td> <a href="../../../../HarborEquipment/Buoys/../../license.html">../../license.html</a> </td>
		</tr>
		<tr style="background-color:silver; border-color:silver;">
			<td style="text-align:center;" colspan="2">  &nbsp; </td>
		</tr>
	</table>

	<p>
		This program uses the
		<a href="https://www.web3d.org/specifications/java/X3DJSAIL.html" target="_blank">X3D Java Scene Access Interface Library (X3DJSAIL)</a>.
		It has been produced using the 
		<a href="https://www.web3d.org/x3d/stylesheets/X3dToJava.xslt" target="_blank">X3dToJava.xslt</a>
		stylesheet
	       (<a href="https://sourceforge.net/p/x3d/code/HEAD/tree/www.web3d.org/x3d/stylesheets/X3dToJava.xslt" target="_blank">version control</a>)
                which is used to create Java source code from an original <code>.x3d</code> model.
	</p>

	* @author Planet 9 Studios, Inc., San Francisco, CA
 */

public class MarkerBuoy
{
	/** Default constructor to create this object. */
	public MarkerBuoy ()
	{
	  initialize();
	}

	/** Create and initialize the X3D model for this object. */
	public final void initialize()
	{
            try { // catch-all
  x3dModel = new X3D().setProfile(X3D.PROFILE_INTERCHANGE).setVersion(X3D.VERSION_3_0)
  .setHead(new head()
    .addMeta(new meta().setName(meta.NAME_TITLE      ).setContent("MarkerBuoy.x3d"))
    .addMeta(new meta().setName(meta.NAME_DESCRIPTION).setContent("Marker Buoy"))
    .addMeta(new meta().setName(meta.NAME_CREATOR    ).setContent("Planet 9 Studios, Inc., San Francisco, CA"))
    .addMeta(new meta().setName("producer").setContent("Christian Greuel, Director of Art and Production"))
    .addMeta(new meta().setName("modelers").setContent("Danny Lee, Christian Greuel"))
    .addMeta(new meta().setName(meta.NAME_REFERENCE  ).setContent("http://www.planet9.com"))
    .addMeta(new meta().setName(meta.NAME_TRANSLATOR ).setContent("Xj3D Format Converter"))
    .addMeta(new meta().setName(meta.NAME_CREATED    ).setContent("17 August 2006"))
    .addMeta(new meta().setName(meta.NAME_TRANSLATED ).setContent("18 August 2006"))
    .addMeta(new meta().setName(meta.NAME_MODIFIED   ).setContent("20 October 2019"))
    .addMeta(new meta().setName(meta.NAME_IDENTIFIER ).setContent("https://www.web3d.org/x3d/content/examples/Savage/HarborEquipment/Buoys/MarkerBuoy.x3d"))
    .addMeta(new meta().setName(meta.NAME_GENERATOR  ).setContent("X3D-Edit, https://www.web3d.org/x3d/tools/X3D-Edit"))
    .addMeta(new meta().setName(meta.NAME_LICENSE    ).setContent("../../license.html")))
  .setScene(new Scene()
    .addChild(new WorldInfo().setTitle("MarkerBuoy.x3d"))
    .addChild(new Transform("MarkerBuoy").setScale(0.2,0.2,0.2)
      .addChild(new Shape()
        .setAppearance(new Appearance()
          .setMaterial(new Material("MarkerBuoy-MATERIAL").setAmbientIntensity(0.0).setDiffuseColor(0.588235,0.588235,0.588235).setShininess(0.145))
          .setTexture(new ImageTexture().setUrl(new String[] {"Textures/MarkerBuoy1.jpg","https://www.web3d.org/x3d/content/examples/Savage/HarborEquipment/Buoys/Textures/MarkerBuoy1.jpg"})))
        .setGeometry(new IndexedFaceSet().setCoordIndex(new int[] {30,1,2,-1,2,29,30,-1,3,26,29,-1,29,2,3,-1,26,3,4,-1,28,5,6,-1,6,27,28,-1,7,25,27,-1,27,6,7,-1,7,0,25,-1,0,8,9,-1,9,1,0,-1,1,9,10,-1,10,2,1,-1,2,10,11,-1,11,3,2,-1,3,11,12,-1,12,4,3,-1,4,12,13,-1,13,5,4,-1,5,13,14,-1,14,6,5,-1,6,14,15,-1,15,7,6,-1,7,15,8,-1,8,0,7,-1,8,16,17,-1,17,9,8,-1,9,17,18,-1,18,10,9,-1,10,18,19,-1,19,11,10,-1,11,19,20,-1,20,12,11,-1,12,20,21,-1,21,13,12,-1,13,21,22,-1,22,14,13,-1,14,22,23,-1,23,15,14,-1,15,23,16,-1,16,8,15,-1,24,17,16,-1,24,18,17,-1,24,19,18,-1,24,20,19,-1,24,21,20,-1,24,22,21,-1,24,23,22,-1,24,16,23,-1,30,25,0,-1,0,1,30,-1,5,28,26,-1,26,4,5,-1}).setNormalIndex(new int[] {10,8,22,-1,22,19,10,-1,47,3,19,-1,19,22,47,-1,3,47,18,-1,36,23,25,-1,25,21,36,-1,0,13,21,-1,21,25,0,-1,0,48,13,-1,48,44,2,-1,2,8,48,-1,8,2,14,-1,14,22,8,-1,22,14,37,-1,37,47,22,-1,47,37,30,-1,30,18,47,-1,18,30,26,-1,26,23,18,-1,23,26,6,-1,6,25,23,-1,25,6,39,-1,39,0,25,-1,0,39,44,-1,44,48,0,-1,44,11,9,-1,9,2,44,-1,2,9,45,-1,45,14,2,-1,14,45,46,-1,46,37,14,-1,37,46,1,-1,1,30,37,-1,30,1,33,-1,33,26,30,-1,26,33,32,-1,32,6,26,-1,6,32,49,-1,49,39,6,-1,39,49,11,-1,11,44,39,-1,34,9,11,-1,34,45,9,-1,34,46,45,-1,34,1,46,-1,34,33,1,-1,34,32,33,-1,34,49,32,-1,34,11,49,-1,10,13,48,-1,48,8,10,-1,23,36,3,-1,3,18,23,-1}).setTexCoordIndex(new int[] {44,45,46,-1,46,47,44,-1,48,49,47,-1,47,46,48,-1,49,48,50,-1,51,52,53,-1,53,54,51,-1,55,56,54,-1,54,53,55,-1,55,57,56,-1,75,76,59,-1,59,45,75,-1,45,59,60,-1,60,46,45,-1,46,60,61,-1,61,48,46,-1,48,61,62,-1,62,50,48,-1,50,62,63,-1,63,52,50,-1,52,63,64,-1,64,53,52,-1,53,64,65,-1,65,55,53,-1,55,65,58,-1,58,57,55,-1,76,77,67,-1,67,59,76,-1,59,67,68,-1,68,60,59,-1,60,68,69,-1,69,61,60,-1,61,69,70,-1,70,62,61,-1,62,70,71,-1,71,63,62,-1,63,71,72,-1,72,64,63,-1,64,72,73,-1,73,65,64,-1,65,73,66,-1,66,58,65,-1,78,67,77,-1,79,68,67,-1,80,69,68,-1,81,70,69,-1,82,71,70,-1,83,72,71,-1,84,73,72,-1,74,66,73,-1,44,85,75,-1,75,45,44,-1,52,51,49,-1,49,50,52,-1})
          .setCoord(new Coordinate("MarkerBuoy-COORD").setPoint(getMarkerBuoy_COORD_6_19_point()))
          .setNormal(new Normal("MarkerBuoy-NORMAL").setVector(new MFVec3f(new double[] {0.5343,0.6585,-0.5298,0.0,-0.663,0.7486,-0.7071,0.0,-0.7071,-0.2,0.9307,0.3061,-0.7771,-0.4413,-0.4486,0.0,0.4413,-0.8973,1.0,0.0,0.0,0.0,-0.4413,0.8973,-0.5344,0.6584,-0.5299,-0.5293,-0.663,-0.5293,-0.2238,0.9322,-0.2841,0.0,-0.663,-0.7486,0.7771,0.4413,0.4486,0.2258,0.932,-0.2832,-1.0,0.0,0.0,0.0,1.0,0.0,0.433,-0.866,0.25,0.0,-0.4413,-0.8973,0.0048,0.6615,0.7499,-0.3836,0.9234,9.0E-4,0.0,-0.866,0.5,0.3836,0.9234,-9.0E-4,-0.7487,0.6628,1.0E-4,0.5279,0.6635,0.53,-0.7771,0.4413,0.4486,0.7487,0.6628,-1.0E-4,0.7071,0.0,0.7071,0.7771,0.4413,-0.4486,0.7771,-0.4413,0.4486,-0.433,-0.866,0.2499,0.0,0.0,1.0,0.433,-0.866,-0.25,0.7486,-0.663,0.0,0.5293,-0.663,0.5293,0.0,-1.0,0.0,0.0,-0.866,-0.5,0.1929,0.9052,0.3785,-0.7071,0.0,0.7071,-0.7771,0.4413,-0.4486,0.7071,0.0,-0.7071,-0.7771,-0.4413,0.4486,0.0,0.4413,0.8973,0.7771,-0.4413,-0.4486,-0.433,-0.866,-0.25,0.0,0.0,-1.0,-0.7486,-0.663,0.0,-0.5293,-0.663,0.5293,-0.5343,0.6585,0.5298,0.0,0.6543,-0.7561,0.5293,-0.663,-0.5293})))
          .setTexCoord(new TextureCoordinate("MarkerBuoy-TEXCOORD").setPoint(getMarkerBuoy_TEXCOORD_6_21_point()))))
      .addChild(new Shape()
        .setAppearance(new Appearance()
          .setMaterial(new Material().setUSE("MarkerBuoy-MATERIAL"))
          .setTexture(new ImageTexture().setUrl(new String[] {"Textures/MarkerBuoy2.jpg","https://www.web3d.org/x3d/content/examples/Savage/HarborEquipment/Buoys/Textures/MarkerBuoy2.jpg"})))
        .setGeometry(new IndexedFaceSet().setCoordIndex(new int[] {32,31,26,-1,26,28,32,-1,34,32,28,-1,27,34,28,-1,33,34,25,-1,25,30,33,-1,31,33,30,-1,29,31,30,-1,25,34,27,-1,26,31,29,-1,36,40,34,-1,36,34,33,-1,35,36,33,-1,35,33,31,-1,37,35,31,-1,37,31,32,-1,38,37,32,-1,39,38,32,-1,39,32,34,-1,39,34,40,-1,41,42,43,-1,41,43,44,-1,41,44,45,-1,41,45,46,-1,41,46,47,-1,41,47,42,-1,49,43,42,-1,42,48,49,-1,50,44,43,-1,43,49,50,-1,51,45,44,-1,44,50,51,-1,52,46,45,-1,45,51,52,-1,53,47,46,-1,46,52,53,-1,48,42,47,-1,47,53,48,-1,49,48,36,-1,36,35,49,-1,35,37,50,-1,50,49,35,-1,51,50,37,-1,37,38,51,-1,38,39,52,-1,52,51,38,-1,53,52,39,-1,39,40,53,-1,36,48,53,-1,53,40,36,-1}).setNormalIndex(new int[] {30,30,30,-1,30,30,30,-1,6,6,6,-1,6,6,6,-1,44,44,44,-1,44,44,44,-1,14,14,14,-1,14,14,14,-1,6,6,6,-1,14,14,14,-1,15,15,15,-1,15,15,15,-1,15,15,15,-1,15,15,15,-1,15,15,15,-1,15,15,15,-1,15,15,15,-1,15,15,15,-1,15,15,15,-1,15,15,15,-1,15,5,38,-1,15,38,24,-1,15,24,41,-1,15,41,12,-1,15,12,27,-1,15,27,5,-1,4,38,5,-1,5,17,4,-1,40,24,38,-1,38,4,40,-1,7,41,24,-1,24,40,7,-1,28,12,41,-1,41,7,28,-1,42,27,12,-1,12,28,42,-1,17,5,27,-1,27,42,17,-1,4,17,35,-1,35,43,4,-1,43,29,40,-1,40,4,43,-1,7,40,29,-1,29,20,7,-1,20,16,28,-1,28,7,20,-1,42,28,16,-1,16,31,42,-1,35,17,42,-1,42,31,35,-1}).setTexCoordIndex(new int[] {38,40,41,-1,41,42,38,-1,38,37,39,-1,43,38,39,-1,38,40,41,-1,41,42,38,-1,38,37,39,-1,43,38,39,-1,42,38,43,-1,42,38,43,-1,0,1,2,-1,0,2,3,-1,4,0,3,-1,4,3,5,-1,6,4,5,-1,6,5,7,-1,8,6,7,-1,9,8,7,-1,9,7,2,-1,9,2,1,-1,10,15,26,-1,10,26,27,-1,10,27,17,-1,10,17,28,-1,10,28,29,-1,10,29,15,-1,30,31,11,-1,11,32,30,-1,33,34,12,-1,12,35,33,-1,32,11,13,-1,13,36,32,-1,30,31,11,-1,11,32,30,-1,33,34,12,-1,12,35,33,-1,32,11,13,-1,13,36,32,-1,14,15,20,-1,20,21,14,-1,21,22,16,-1,16,14,21,-1,17,16,22,-1,22,23,17,-1,23,24,18,-1,18,17,23,-1,19,18,24,-1,24,25,19,-1,20,15,19,-1,19,25,20,-1})
          .setCoord(new Coordinate().setUSE("MarkerBuoy-COORD"))
          .setNormal(new Normal().setUSE("MarkerBuoy-NORMAL"))
          .setTexCoord(new TextureCoordinate().setUSE("MarkerBuoy-TEXCOORD"))))));
            }
            catch (Exception ex)
            {       
                System.err.println ("*** Further hints on X3DJSAIL errors and exceptions at");
                System.err.println ("*** https://www.web3d.org/specifications/java/X3DJSAIL.html");
                throw (ex);
            }
	}
	// end of initialize() method


		/** Large attribute array: Coordinate DEF='MarkerBuoy-COORD' point field, scene-graph level=6, element #19, 162 total numbers made up of 54 3-tuple values.
		 * Reassemble split array as single method to improve readability and runnability.
		 * Provide large array values via separate methods, hoping to avoid 'code too large' Java compilation errors. 
		 * Individual Java methods (including aggregated initializations) are limited to 64KB.
		 * @see https://stackoverflow.com/questions/2407912/code-too-large-compilation-error-in-java
		 * @see https://stackoverflow.com/questions/11437905/java-too-many-constants-jvm-error
		 */
		private MFVec3f getMarkerBuoy_COORD_6_19_point()
		{
			MFVec3f MarkerBuoy_COORD_6_19_point = new MFVec3f(new double[] {0.0,0.912901,-0.791902,-0.55996,0.912901,-0.559959,-0.791902,0.912901,0.0,-0.559959,0.912901,0.55996,0.0,0.912901,0.791902,0.55996,0.912901,0.559959,0.791902,0.912901,0.0,0.559959,0.912901,-0.55996,0.0,0.120999,-1.11992,-0.791902,0.120999,-0.791902,-1.11992,0.120999,0.0,-0.791902,0.120999,0.791902,0.0,0.120999,1.11992,0.791902,0.120999,0.791902,1.11992,0.120999,0.0,0.791902,0.120999,-0.791903,0.0,-0.670903,-0.791902,-0.55996,-0.670903,-0.559959,-0.791902,-0.670903,0.0,-0.559959,-0.670903,0.55996,0.0,-0.670903,0.791902,0.55996,-0.670903,0.559959,0.791902,-0.670903,0.0,0.559959,-0.670903,-0.55996,0.0,-0.99892,0.0,0.098144,1.16959,-0.183289,-0.098144,1.16959,0.183289,0.098144,1.20027,0.0,0.098144,1.16959,0.183289,-0.098144,1.20027,0.0,-0.098144,1.16959,-0.183289,-0.098144,1.37863,0.183289,0.098144,1.37863,0.183289,-0.098144,1.37863,-0.183289,0.098144,1.37863,-0.183289,-0.05577,1.37863,-0.032199,0.0,1.37863,-0.064398,-0.05577,1.37863,0.032199,0.0,1.37863,0.064398,0.05577,1.37863,0.032199,0.05577,1.37863,-0.032199,0.0,1.72158,0.0,0.0,1.62655,-0.164602,-0.14255,1.62655,-0.082301,-0.14255,1.62655,0.082301,0.0,1.62655,0.164602,0.14255,1.62655,0.082301,0.14255,1.62655,-0.082301,0.0,1.43648,-0.164602,-0.14255,1.43648,-0.082301,-0.14255,1.43648,0.082301,0.0,1.43648,0.164602,0.14255,1.43648,0.082301,0.14255,1.43648,-0.082301});
			return MarkerBuoy_COORD_6_19_point;
		}
		/** Large attribute array: TextureCoordinate DEF='MarkerBuoy-TEXCOORD' point field, scene-graph level=6, element #21, 172 total numbers made up of 86 2-tuple values.
		 * Reassemble split array as single method to improve readability and runnability.
		 * Provide large array values via separate methods, hoping to avoid 'code too large' Java compilation errors. 
		 * Individual Java methods (including aggregated initializations) are limited to 64KB.
		 * @see https://stackoverflow.com/questions/2407912/code-too-large-compilation-error-in-java
		 * @see https://stackoverflow.com/questions/11437905/java-too-many-constants-jvm-error
		 */
		private MFVec2f getMarkerBuoy_TEXCOORD_6_21_point()
		{
			MFVec2f MarkerBuoy_TEXCOORD_6_21_point = new MFVec2f(new double[] {0.498419,0.284616,0.781362,0.247681,0.996339,0.420993,4.99E-4,0.420993,0.215477,0.247681,4.99E-4,4.99E-4,0.215477,0.173811,0.996339,4.99E-4,0.498419,0.136876,0.781361,0.173811,0.5,0.756234,0.5,0.859768,0.25025,0.859768,4.99E-4,0.859768,0.9995,0.872357,0.5,0.98848,0.999501,0.640111,0.5,0.523988,4.99E-4,0.640111,4.99E-4,0.872357,0.5,0.847096,0.695422,0.801665,0.695422,0.710803,0.5,0.665371,0.304578,0.710803,0.304578,0.801665,4.99E-4,0.872357,4.99E-4,0.640111,0.9995,0.640111,0.999501,0.872357,0.9995,0.602344,0.9995,0.859768,0.5,0.602344,0.74975,0.602344,0.74975,0.859768,0.25025,0.602344,4.99E-4,0.602344,4.99E-4,0.446283,0.9995,0.446283,0.187029,0.015249,4.99E-4,0.446283,4.99E-4,4.99E-4,0.9995,4.99E-4,0.5,0.06591,0.156486,0.93885,0.25,0.754033,0.5,0.754033,0.5,0.971664,0.75,0.754033,0.843514,0.93885,1.0,0.754033,1.15649,0.93885,1.25,0.754033,1.5,0.754033,1.5,0.971664,1.75,0.754033,1.84351,0.93885,2.0,0.754033,2.0,0.505777,0.25,0.505777,0.5,0.505777,0.75,0.505777,1.0,0.505777,1.25,0.505777,1.5,0.505777,1.75,0.505777,2.0,0.254138,0.25,0.254138,0.5,0.254138,0.75,0.254138,1.0,0.254138,1.25,0.254138,1.5,0.254138,1.75,0.254138,1.875,0.0,0.0,0.754033,0.0,0.505777,0.0,0.254138,0.125,0.0,0.375,0.0,0.625,0.0,0.875,0.0,1.125,0.0,1.375,0.0,1.625,0.0,-0.156486,0.93885});
			return MarkerBuoy_TEXCOORD_6_21_point;
		}

	/** The initialized model object, created within initialize() method. */
	private X3D x3dModel;

	/** 
	 * Provide a 
	 * <a href="https://dzone.com/articles/java-copy-shallow-vs-deep-in-which-you-will-swim" target="_blank">shallow copy</a>
	 * of the X3D model.
	 * @see <a href="https://www.web3d.org/specifications/java/javadoc/org/web3d/x3d/jsail/Core/X3D.html">X3D</a>
	 * @return MarkerBuoy model
	 */
	public X3D getX3dModel()
	{	  
		return x3dModel;
	}
	   
    /** 
     * Default main() method provided for test purposes, uses CommandLine to set global ConfigurationProperties for this object.
     * @param args array of input parameters, provided as arguments
     * @see <a href="https://www.web3d.org/specifications/java/javadoc/org/web3d/x3d/jsail/Core/X3D.html#handleArguments-java.lang.String:A-">X3D.handleArguments(args)</a>
     * @see <a href="https://www.web3d.org/specifications/java/javadoc/org/web3d/x3d/jsail/Core/X3D.html#validationReport--">X3D.validationReport()</a>
     * @see <a href="https://www.web3d.org/specifications/java/javadoc/org/web3d/x3d/jsail/CommandLine.html">CommandLine</a>
     * @see <a href="https://www.web3d.org/specifications/java/javadoc/org/web3d/x3d/jsail/CommandLine.html#USAGE">CommandLine.USAGE</a>
     * @see <a href="https://www.web3d.org/specifications/java/javadoc/org/web3d/x3d/jsail/ConfigurationProperties.html">ConfigurationProperties</a>
     */
    public static void main(String args[])
    {
        System.out.println("Build this X3D model, showing validation diagnostics...");
        X3D thisExampleX3dModel = new MarkerBuoy().getX3dModel();
//      System.out.println("X3D model construction complete.");
	
        // next handle command line arguments
        boolean hasArguments = (args != null) && (args.length > 0);
        boolean validate = true; // default
        boolean argumentsLoadNewModel = false;
        String  fileName = new String();

        if (args != null)
        {
                for (String arg : args)
                {
                        if (arg.toLowerCase().startsWith("-v") || arg.toLowerCase().contains("validate"))
                        {
                                validate = true; // making sure
                        }
                        if (arg.toLowerCase().endsWith(X3D.FILE_EXTENSION_X3D) ||
                                arg.toLowerCase().endsWith(X3D.FILE_EXTENSION_CLASSICVRML) ||
                                arg.toLowerCase().endsWith(X3D.FILE_EXTENSION_X3DB) ||
                                arg.toLowerCase().endsWith(X3D.FILE_EXTENSION_VRML97) ||
                                arg.toLowerCase().endsWith(X3D.FILE_EXTENSION_EXI) ||
                                arg.toLowerCase().endsWith(X3D.FILE_EXTENSION_GZIP) ||
                                arg.toLowerCase().endsWith(X3D.FILE_EXTENSION_ZIP) ||
                                arg.toLowerCase().endsWith(X3D.FILE_EXTENSION_HTML) ||
                                arg.toLowerCase().endsWith(X3D.FILE_EXTENSION_XHTML))
                        {
                                argumentsLoadNewModel = true;
                                fileName = arg;
                        }
                }
        }
        if      (argumentsLoadNewModel)
                System.out.println("WARNING: \"Savage.HarborEquipment.Buoys.MarkerBuoy\" model invocation is attempting to load file \"" + fileName + "\" instead of simply validating itself... file loading ignored.");
        else if (hasArguments) // if no arguments provided, this method produces usage warning
                thisExampleX3dModel.handleArguments(args);
	
        if (validate)
        {
            //  System.out.println("--- TODO fix duplicated outputs ---"); // omit when duplicated outputs problem is solved/refactored
		String validationResults = thisExampleX3dModel.validationReport();
            //  System.out.println("-----------------------------------"); // omit when duplicated outputs problem is solved/refactored
                System.out.print("Savage.HarborEquipment.Buoys.MarkerBuoy self-validation test confirmation: ");
                if (!validationResults.equals("success"))
                    System.out.println();
                System.out.println(validationResults.trim());

                // experimental: test X3DJSAIL output files
                // HarborEquipment/Buoys/MarkerBuoy_JavaExport.* file validation is checked when building X3D Example Archives
                String filenameX3D  = "HarborEquipment/Buoys/MarkerBuoy_JavaExport.x3d"; 
                String filenameX3DV = "HarborEquipment/Buoys/MarkerBuoy_JavaExport.x3dv"; 
                String filenameJSON = "HarborEquipment/Buoys/MarkerBuoy_JavaExport.json";
                thisExampleX3dModel.toFileX3D        (filenameX3D);
                thisExampleX3dModel.toFileClassicVRML(filenameX3DV);
// TODO         thisExampleX3dModel.toFileJSON       (filenameJSON);
        }
    }
}
