Exemplo n.º 1
0
 /** {@inheritDoc} */
 public void copy(ShapeAttributes attributes) {
   if (attributes != null) {
     this.drawInterior = attributes.isDrawInterior();
     this.drawOutline = attributes.isDrawOutline();
     this.enableAntialiasing = attributes.isEnableAntialiasing();
     this.enableLighting = attributes.isEnableLighting();
     this.interiorMaterial = attributes.getInteriorMaterial();
     this.outlineMaterial = attributes.getOutlineMaterial();
     this.interiorOpacity = attributes.getInteriorOpacity();
     this.outlineOpacity = attributes.getOutlineOpacity();
     this.outlineWidth = attributes.getOutlineWidth();
     this.outlineStippleFactor = attributes.getOutlineStippleFactor();
     this.outlineStipplePattern = attributes.getOutlineStipplePattern();
     this.interiorImageSource = attributes.getInteriorImageSource();
     this.interiorImageScale = attributes.getInteriorImageScale();
     this.updateModifiedTime();
   }
 }
Exemplo n.º 2
0
  public BasicShapeAttributes(ShapeAttributes attributes) {
    if (attributes == null) {
      String message = Logging.getMessage("nullValue.AttributesIsNull");
      Logging.logger().severe(message);
      throw new IllegalArgumentException(message);
    }

    this.drawInterior = attributes.isDrawInterior();
    this.drawOutline = attributes.isDrawOutline();
    this.enableAntialiasing = attributes.isEnableAntialiasing();
    this.enableLighting = attributes.isEnableLighting();
    this.interiorMaterial = attributes.getInteriorMaterial();
    this.outlineMaterial = attributes.getOutlineMaterial();
    this.interiorOpacity = attributes.getInteriorOpacity();
    this.outlineOpacity = attributes.getOutlineOpacity();
    this.outlineWidth = attributes.getOutlineWidth();
    this.outlineStippleFactor = attributes.getOutlineStippleFactor();
    this.outlineStipplePattern = attributes.getOutlineStipplePattern();
    this.interiorImageSource = attributes.getInteriorImageSource();
    this.interiorImageScale = attributes.getInteriorImageScale();
    this.updateModifiedTime();
  }