예제 #1
0
        /**
         * Copies all values, including null values, from another instance to this one.
         *
         * @param attrs the instance to copy values from.
         */
        public void copy(PointPlacemarkAttributes attrs)
        {
            if (attrs != null)
            {
                this.setImageAddress(attrs.getImageAddress());
                this.setScale(attrs.getScale());
                this.setHeading(attrs.getHeading());
                this.setHeadingReference(attrs.getHeadingReference());
                this.setPitch(attrs.getPitch());
                this.setImageOffset(attrs.getImageOffset());
                this.setImageColor(attrs.getImageColor());
                this.setLineWidth(attrs.getLineWidth());
                this.setLineMaterial(attrs.getLineMaterial());
                this.setAntiAliasHint(attrs.getAntiAliasHint());
                this.setLabelFont(attrs.getLabelFont());
                this.setLabelOffset(attrs.getLabelOffset());
                this.setLabelMaterial(attrs.getLabelMaterial());
                this.setLabelScale(attrs.getLabelScale());
                this.setUsePointAsDefaultImage(attrs.isUsePointAsDefaultImage());
                this.setDrawImage(attrs.isDrawImage());
                this.setDrawLabel(attrs.isDrawLabel());

                // Calling setImage has side effects, so just assign the current value without calling setImage.
                this.image = attrs.image;
            }
        }
예제 #2
0
 /**
  * Constructs an instance and initializes it to the values in a specified instance.
  *
  * @param attrs the instance from which to copy the initial attribute values of this. May be null.
  */
 public PointPlacemarkAttributes(PointPlacemarkAttributes attrs)
 {
     this.copy(attrs);
 }