Example usage for javax.swing JProgressBar getModel

List of usage examples for javax.swing JProgressBar getModel

Introduction

In this page you can find the example usage for javax.swing JProgressBar getModel.

Prototype

public BoundedRangeModel getModel() 

Source Link

Document

Returns the data model used by this progress bar.

Usage

From source file:Main.java

public static void main(String[] argv) throws Exception {
    int minimum = 0;
    int maximum = 100;
    JProgressBar progress = new JProgressBar(minimum, maximum);
    int newValue = 10;
    int newMin = 0;
    int newMax = 100;
    progress.getModel().setRangeProperties(newValue, 0, newMin, newMax, false);
}