class AppendRectangleToPath extends GraphicsOperatorProcessor
{

    public AppendRectangleToPath(PDFGraphicsStreamEngine context)
    {
        super(context);
    }

    @Override
    public void process(Operator operator, List<COSBase> operands) throws IOException
    {<FILL_FUNCTION_BODY>}

    @Override
    public String getName()
    {
        return OperatorName.APPEND_RECT;
    }
}

        if (operands.size() < 4)
        {
            throw new MissingOperandException(operator, operands);
        }
        if (!checkArrayTypesClass(operands, COSNumber.class))
        {
            return;
        }
        COSNumber x = (COSNumber) operands.get(0);
        COSNumber y = (COSNumber) operands.get(1);
        COSNumber w = (COSNumber) operands.get(2);
        COSNumber h = (COSNumber) operands.get(3);

        float x1 = x.floatValue();
        float y1 = y.floatValue();

        // create a pair of coordinates for the transformation
        float x2 = w.floatValue() + x1;
        float y2 = h.floatValue() + y1;

        PDFGraphicsStreamEngine context = getGraphicsContext();
        Point2D p0 = context.transformedPoint(x1, y1);
        Point2D p1 = context.transformedPoint(x2, y1);
        Point2D p2 = context.transformedPoint(x2, y2);
        Point2D p3 = context.transformedPoint(x1, y2);

        context.appendRectangle(p0, p1, p2, p3);
    
<no_super_class>