Example usage for javax.print.event PrintServiceAttributeListener interface-usage

List of usage examples for javax.print.event PrintServiceAttributeListener interface-usage

Introduction

In this page you can find the example usage for javax.print.event PrintServiceAttributeListener interface-usage.

Usage

From source file Main.java

class MyPrintServiceAttributeListener implements PrintServiceAttributeListener {
    public void attributeUpdate(PrintServiceAttributeEvent psae) {
        PrintService service = psae.getPrintService();
        Attribute[] attrs = psae.getAttributes().toArray();
        for (int i = 0; i < attrs.length; i++) {
            String attrName = attrs[i].getName();