/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * TapeImagePluginPanel.java
 *
 * Created on 6.12.2008, 15:00:35
 */

package turgen.plugin;

import turgen.generator.PulseCrate;

/**
 *
 * @author michael
 */
public class TapeImagePluginPanel extends javax.swing.JPanel {

    public InOutProvider ioProvider;

    /** Creates new form TapeImagePluginPanel */
    public TapeImagePluginPanel() {
        initComponents();
    }

    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        pChunkList = new javax.swing.JPanel();
        jScrollPane1 = new javax.swing.JScrollPane();
        jtaSupportedChunks = new javax.swing.JTextArea();
        jLabel1 = new javax.swing.JLabel();

        setLayout(new java.awt.BorderLayout());

        pChunkList.setLayout(new java.awt.BorderLayout(0, 2));

        jScrollPane1.setBorder(null);

        jtaSupportedChunks.setBackground(javax.swing.UIManager.getDefaults().getColor("control"));
        jtaSupportedChunks.setColumns(20);
        jtaSupportedChunks.setEditable(false);
        jtaSupportedChunks.setFont(new java.awt.Font("Monospaced", 0, 12)); // NOI18N
        jtaSupportedChunks.setLineWrap(true);
        jtaSupportedChunks.setRows(5);
        jScrollPane1.setViewportView(jtaSupportedChunks);

        pChunkList.add(jScrollPane1, java.awt.BorderLayout.CENTER);

        jLabel1.setFont(new java.awt.Font("Dialog", 0, 12)); // NOI18N
        jLabel1.setText("Tape image chunks supported on input:");
        pChunkList.add(jLabel1, java.awt.BorderLayout.NORTH);

        add(pChunkList, java.awt.BorderLayout.NORTH);
    }// </editor-fold>//GEN-END:initComponents


    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JLabel jLabel1;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JTextArea jtaSupportedChunks;
    private javax.swing.JPanel pChunkList;
    // End of variables declaration//GEN-END:variables

     public SimplePlaylistItem getRecord() {
        return new SimplePlaylistItem(ioProvider.getInFile(),ioProvider.getOutFile(),new PulseCrate(),"",null);
    }

    public void fill(SimplePlaylistItem dpr) {
        
    }

    public void fillChunkList(String[] supportedChunks) {
        jtaSupportedChunks.setText("");
        for(int i=0;i<supportedChunks.length;i++) {
            jtaSupportedChunks.append(supportedChunks[i]+" ");
        }
    }

}
