You can subscribe to this list here.
2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(12) |
Jul
(47) |
Aug
(21) |
Sep
(5) |
Oct
(17) |
Nov
|
Dec
(8) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(4) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(9) |
Aug
|
Sep
(3) |
Oct
|
Nov
|
Dec
|
2003 |
Jan
|
Feb
(6) |
Mar
(7) |
Apr
(8) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(9) |
Nov
|
Dec
|
2004 |
Jan
(8) |
Feb
(46) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2005 |
Jan
|
Feb
|
Mar
(2) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2006 |
Jan
(27) |
Feb
(2) |
Mar
|
Apr
(64) |
May
|
Jun
|
Jul
(11) |
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
(2) |
From: <yas...@ho...> - 2006-12-19 17:25:47
|
is ok _________________________________________________________________ Der neue MSN Messenger. Schreiben.Sehen.Hören. Wie im echten Leben. - http://www.imagine-msn.com/messenger/default2.aspx?locale=de Jetzt herunterladen! |
From: <yas...@ho...> - 2006-12-19 17:24:54
|
----------- _________________________________________________________________ Wenn Ihnen E-Mail nicht schnell genug ist: MSN Messenger! - http://www.imagine-msn.com/messenger/default2.aspx?locale=de Kostenlos downloaden! |
From: Gordon M. <go...@us...> - 2006-10-19 05:09:37
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.ui/src/org/bitpedia/collider/ui In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv18749/plugins/org.bitpedia.collider.ui/src/org/bitpedia/collider/ui Modified Files: MainDialog.java Log Message: [ 1579276 ] jBitCollider patch for "Files processed" counter * MainDialog.java reset filesProcessed for new batch submission patch donated by 'TheParanoidOne' -- thanks! Index: MainDialog.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.ui/src/org/bitpedia/collider/ui/MainDialog.java,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -r1.3 -r1.4 *** MainDialog.java 14 Jul 2006 04:58:39 -0000 1.3 --- MainDialog.java 19 Oct 2006 05:09:33 -0000 1.4 *************** *** 1,478 **** ! /* (PD) 2006 The Bitzi Corporation ! * Please see http://bitzi.com/publicdomain for more info. ! * ! * $Id$ ! */ ! package org.bitpedia.collider.ui; ! ! import java.awt.BorderLayout; ! import java.awt.datatransfer.DataFlavor; ! import java.awt.datatransfer.Transferable; ! import java.awt.datatransfer.UnsupportedFlavorException; ! import java.awt.dnd.DnDConstants; ! import java.awt.dnd.DropTarget; ! import java.awt.dnd.DropTargetDragEvent; ! import java.awt.dnd.DropTargetDropEvent; ! import java.awt.dnd.DropTargetEvent; ! import java.awt.dnd.DropTargetListener; ! import java.awt.event.ActionEvent; ! import java.awt.event.ActionListener; ! import java.io.BufferedReader; ! import java.io.File; ! import java.io.FileNotFoundException; ! import java.io.IOException; ! import java.io.PrintWriter; ! import java.io.Reader; ! import java.net.URI; ! import java.net.URISyntaxException; ! import java.net.URL; ! import java.util.ArrayList; ! import java.util.Collection; ! import java.util.LinkedList; ! import java.util.List; ! ! import javax.swing.JButton; ! import javax.swing.JCheckBox; ! import javax.swing.JFileChooser; ! import javax.swing.JFrame; ! import javax.swing.JLabel; ! import javax.swing.JOptionPane; ! import javax.swing.JPanel; ! import javax.swing.JProgressBar; ! import javax.swing.JTextArea; ! import javax.swing.Spring; ! import javax.swing.SpringLayout; ! import javax.swing.SwingConstants; ! import javax.swing.SwingUtilities; ! ! import org.bitpedia.collider.core.Bitcollider; ! import org.bitpedia.collider.core.Submission; ! ! import edu.stanford.ejalbert.BrowserLauncher; ! import edu.stanford.ejalbert.exception.BrowserLaunchingExecutionException; ! import edu.stanford.ejalbert.exception.BrowserLaunchingInitializingException; ! import edu.stanford.ejalbert.exception.UnsupportedOperatingSystemException; ! ! public class MainDialog extends JPanel implements ActionListener, ! DropTargetListener, Bitcollider.Progress { ! ! public static final int GAP = 6; ! ! private Collection fmtHandlers; ! ! private JFrame frame; ! ! private SpringLayout layout = new SpringLayout(); ! ! private JLabel lblCurFile = new JLabel("Current File:"); ! ! private JProgressBar pbCurFile = new JProgressBar(0, 100); ! ! private JLabel lblOverallProgress = new JLabel("Overall progress:"); ! ! private JProgressBar pbOverallProgress = new JProgressBar(0, 100); ! ! private JLabel lblFilesToProcess = new JLabel("0 files to process", ! SwingConstants.CENTER); ! ! private JLabel lblFilesProcessed = new JLabel("0 files processed", ! SwingConstants.CENTER); ! ! private JLabel lblFilesSkipped = new JLabel("0 files skipped", ! SwingConstants.CENTER); ! ! private JTextArea taHint = new JTextArea( ! " (1) Drag files onto this window\n" ! + " (2) The Bitcollider extracts identifiers and metadata\n" ! + " (3) Your default web browser will launch to submit the info"); ! ! private JCheckBox chbCloseWindow = new JCheckBox( ! "Close window after processing", false); ! ! private JCheckBox chbDontShowForSmall = new JCheckBox( ! "Don't show window for small files", true); ! ! private JButton btnAbout = new JButton("About"); ! ! private JButton btnBrowse = new JButton("Browse"); ! ! private JButton btnClose = new JButton("Close"); ! ! private Spring sprPnlWidth = new WidthSpring(this); ! ! private JFileChooser fileChooser = new JFileChooser(); ! ! private int filesSkipped = 0; ! ! private int filesProcessed = 0; ! ! private int filesToProcess = 0; ! ! private boolean noSubmitting = false; ! ! private String alternateUrl; ! ! private boolean md5 = false; ! ! private boolean crc32 = false; ! ! public MainDialog(JFrame frame) { ! ! this.frame = frame; ! ! fileChooser.setMultiSelectionEnabled(true); ! ! setLayout(layout); ! ! add(lblCurFile); ! layout.putConstraint(SpringLayout.NORTH, lblCurFile, GAP, ! SpringLayout.NORTH, this); ! layout.putConstraint(SpringLayout.WEST, lblCurFile, GAP, ! SpringLayout.WEST, this); ! ! add(pbCurFile); ! layout.putConstraint(SpringLayout.EAST, pbCurFile, -GAP, ! SpringLayout.EAST, this); ! layout.putConstraint(SpringLayout.WEST, pbCurFile, GAP, ! SpringLayout.WEST, this); ! layout.putConstraint(SpringLayout.NORTH, pbCurFile, GAP, ! SpringLayout.SOUTH, lblCurFile); ! ! add(lblOverallProgress); ! layout.putConstraint(SpringLayout.NORTH, lblOverallProgress, GAP, ! SpringLayout.SOUTH, pbCurFile); ! layout.putConstraint(SpringLayout.WEST, lblOverallProgress, GAP, ! SpringLayout.WEST, this); ! ! add(pbOverallProgress); ! layout.putConstraint(SpringLayout.EAST, pbOverallProgress, -GAP, ! SpringLayout.EAST, this); ! layout.putConstraint(SpringLayout.WEST, pbOverallProgress, GAP, ! SpringLayout.WEST, this); ! layout.putConstraint(SpringLayout.NORTH, pbOverallProgress, GAP, ! SpringLayout.SOUTH, lblOverallProgress); ! ! Spring lblWidth = Spring.scale(Spring.sum(sprPnlWidth, Spring ! .constant(-4 * GAP)), 1f / 3f); ! ! add(lblFilesToProcess); ! layout.putConstraint(SpringLayout.NORTH, lblFilesToProcess, GAP, ! SpringLayout.SOUTH, pbOverallProgress); ! layout.putConstraint(SpringLayout.WEST, lblFilesToProcess, GAP, ! SpringLayout.WEST, this); ! layout.getConstraints(lblFilesToProcess).setWidth(lblWidth); ! ! add(lblFilesProcessed); ! layout.putConstraint(SpringLayout.NORTH, lblFilesProcessed, GAP, ! SpringLayout.SOUTH, pbOverallProgress); ! layout.putConstraint(SpringLayout.WEST, lblFilesProcessed, GAP, ! SpringLayout.EAST, lblFilesToProcess); ! layout.getConstraints(lblFilesProcessed).setWidth(lblWidth); ! ! add(lblFilesSkipped); ! layout.putConstraint(SpringLayout.EAST, lblFilesSkipped, -GAP, ! SpringLayout.EAST, this); ! layout.putConstraint(SpringLayout.WEST, lblFilesSkipped, GAP, ! SpringLayout.EAST, lblFilesProcessed); ! layout.putConstraint(SpringLayout.NORTH, lblFilesSkipped, GAP, ! SpringLayout.SOUTH, pbOverallProgress); ! layout.getConstraints(lblFilesSkipped).setWidth(lblWidth); ! ! add(taHint); ! taHint.setEditable(false); ! taHint.setFocusable(false); ! taHint.setBackground(this.getBackground()); ! layout.putConstraint(SpringLayout.EAST, taHint, -GAP, ! SpringLayout.EAST, this); ! layout.putConstraint(SpringLayout.WEST, taHint, GAP, SpringLayout.WEST, ! this); ! layout.putConstraint(SpringLayout.NORTH, taHint, GAP, ! SpringLayout.SOUTH, lblFilesToProcess); ! ! add(chbCloseWindow); ! layout.putConstraint(SpringLayout.NORTH, chbCloseWindow, GAP, ! SpringLayout.SOUTH, taHint); ! layout.putConstraint(SpringLayout.WEST, chbCloseWindow, GAP, ! SpringLayout.WEST, this); ! ! add(chbDontShowForSmall); ! layout.putConstraint(SpringLayout.NORTH, chbDontShowForSmall, GAP, ! SpringLayout.SOUTH, chbCloseWindow); ! layout.putConstraint(SpringLayout.WEST, chbDontShowForSmall, GAP, ! SpringLayout.WEST, this); ! ! Spring btnWidth = Spring.scale(Spring.sum(sprPnlWidth, Spring ! .constant(-4 * GAP)), 1f / 3f); ! ! add(btnAbout); ! btnAbout.addActionListener(this); ! layout.putConstraint(SpringLayout.NORTH, btnAbout, GAP, ! SpringLayout.SOUTH, chbCloseWindow); ! layout.putConstraint(SpringLayout.WEST, btnAbout, GAP, ! SpringLayout.WEST, this); ! layout.putConstraint(SpringLayout.SOUTH, btnAbout, -GAP, ! SpringLayout.SOUTH, this); ! layout.getConstraints(btnAbout).setWidth(btnWidth); ! ! add(btnBrowse); ! btnBrowse.addActionListener(this); ! layout.putConstraint(SpringLayout.NORTH, btnBrowse, GAP, ! SpringLayout.SOUTH, chbCloseWindow); ! layout.putConstraint(SpringLayout.WEST, btnBrowse, GAP, ! SpringLayout.EAST, btnAbout); ! layout.putConstraint(SpringLayout.SOUTH, btnBrowse, -GAP, ! SpringLayout.SOUTH, this); ! layout.getConstraints(btnBrowse).setWidth(btnWidth); ! ! add(btnClose); ! btnClose.addActionListener(this); ! layout.putConstraint(SpringLayout.EAST, btnClose, -GAP, ! SpringLayout.EAST, this); ! layout.putConstraint(SpringLayout.NORTH, btnClose, GAP, ! SpringLayout.SOUTH, chbCloseWindow); ! layout.putConstraint(SpringLayout.WEST, btnClose, GAP, ! SpringLayout.EAST, btnBrowse); ! layout.putConstraint(SpringLayout.SOUTH, btnClose, -GAP, ! SpringLayout.SOUTH, this); ! layout.getConstraints(btnClose).setWidth(btnWidth); ! ! new DropTarget(this, this); ! new DropTarget(taHint, this); ! } ! ! public void configure(boolean noSubmitting, String alternateUrl, boolean md5, boolean crc32) { ! ! this.noSubmitting = noSubmitting; ! this.alternateUrl = alternateUrl; ! this.md5 = md5; ! this.crc32 = crc32; ! } ! ! public static void main(String[] args) { ! ! JFrame frame = new JFrame("jBitcollider"); ! frame.getContentPane().setLayout(new BorderLayout()); ! frame.getContentPane().add("Center", new MainDialog(frame)); ! frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); ! frame.setSize(450, 300); ! frame.setResizable(false); ! frame.setLocationRelativeTo(null); ! frame.setVisible(true); ! } ! ! public void actionPerformed(ActionEvent event) { ! ! if (event.getSource() == btnAbout) { ! JOptionPane ! .showMessageDialog( ! null, ! "jBitcollider 0.1.0 \n" ! + "(PD) 2006 The Bitzi Corporation\n\n" ! + "For more information about the jBitcollider and Bitzi's Free\n" ! + "Universal Media Catalog , please visit http://bitzi.com", ! "About", JOptionPane.INFORMATION_MESSAGE); ! } else if (event.getSource() == btnBrowse) { ! ! int ret = fileChooser.showOpenDialog(frame); ! if(ret == JFileChooser.APPROVE_OPTION) { ! File[] selFiles = fileChooser.getSelectedFiles(); ! List files = new LinkedList(); ! for (int i = 0; i < selFiles.length; i++) { ! files.add(selFiles[i].getPath()); ! } ! executeBitcollider(files); ! } ! } else if (event.getSource() == btnClose) { ! System.exit(0); ! } ! ! } ! ! public void setSize(int width, int height) { ! super.setSize(width, height); ! ! System.out.println("setSize: " + width + ", " + height); ! } ! ! private void processDtde(DropTargetDragEvent dtde) { ! ! DataFlavor[] flavors = dtde.getTransferable().getTransferDataFlavors(); ! for (int i = 0; i < flavors.length; i++) { ! if (flavors[i].isFlavorJavaFileListType()) { ! dtde.acceptDrag(DnDConstants.ACTION_MOVE); ! return; ! } else if (flavors[i].getMimeType().startsWith("text/uri-list") ! && flavors[i].getRepresentationClass() == Reader.class) { ! dtde.acceptDrag(DnDConstants.ACTION_MOVE); ! return; ! } ! } ! ! dtde.rejectDrag(); ! } ! ! public void dragEnter(DropTargetDragEvent dtde) { ! ! processDtde(dtde); ! } ! ! public void dragOver(DropTargetDragEvent dtde) { ! ! processDtde(dtde); ! } ! ! public void dropActionChanged(DropTargetDragEvent dtde) { ! ! processDtde(dtde); ! } ! ! public void dragExit(DropTargetEvent dtde) { ! } ! ! private void executeBitcollider(final List files) { ! ! final Bitcollider bc = new Bitcollider(fmtHandlers); ! bc.setCalcCrc32(crc32); ! bc.setCalcMd5(md5); ! bc.setPreview(true); ! Submission prevSub = bc.generateSubmission(files, null, true); ! ! filesToProcess = prevSub.getNumBitprints(); ! lblFilesToProcess.setText(""+filesToProcess+" files to process"); ! ! Thread bt = new Thread(new Runnable() { ! ! public void run() { ! ! try { ! bc.setPreview(false); ! bc.setProgress(MainDialog.this); ! Submission submission = bc.generateSubmission(files, null, ! true); ! String tmpdir = System.getProperty("java.io.tmpdir"); ! String sep = System.getProperty("file.separator"); ! if ((null != tmpdir) && (!"".equals(tmpdir)) && (!tmpdir.endsWith(sep))) { ! tmpdir = tmpdir + sep; ! } ! String htmlFileName = tmpdir + "bitprint.html"; ! PrintWriter pw = new PrintWriter(htmlFileName); ! try { ! submission.setAutoSubmit(!noSubmitting); ! submission.makeHtml(pw, alternateUrl); ! } finally { ! pw.close(); ! } ! ! BrowserLauncher bl = new BrowserLauncher(null); ! bl.openURLinBrowser("file://localhost/"+htmlFileName); ! ! SwingUtilities.invokeLater(new Runnable() { ! ! public void run() { ! ! pbCurFile.setValue(0); ! pbOverallProgress.setValue(0); ! lblFilesToProcess.setText("0 files to process"); ! ! } ! ! }); ! ! } catch (FileNotFoundException e) { ! } catch (BrowserLaunchingInitializingException e) { ! } catch (UnsupportedOperatingSystemException e) { ! } catch (BrowserLaunchingExecutionException e) { ! } ! } ! ! }); ! ! bt.start(); ! ! } ! ! public void drop(DropTargetDropEvent dtde) { ! ! DataFlavor[] flavors = dtde.getTransferable().getTransferDataFlavors(); ! Transferable tr = dtde.getTransferable(); ! for (int i = 0; i < flavors.length; i++) { ! if (flavors[i].isFlavorJavaFileListType()) { ! dtde.acceptDrop(DnDConstants.ACTION_MOVE); ! try { ! List files = (List) tr.getTransferData(flavors[i]); ! executeBitcollider(files); ! } catch (UnsupportedFlavorException ufe) { ! } catch (IOException e) { ! } ! return; ! } else if (flavors[i].getMimeType().startsWith("text/uri-list") ! && flavors[i].getRepresentationClass() == Reader.class) { ! dtde.acceptDrop(DnDConstants.ACTION_MOVE); ! try { ! BufferedReader reader = new BufferedReader((Reader)tr.getTransferData(flavors[i])); ! String line; ! List files = new ArrayList(); ! while((line = reader.readLine()) != null) { ! try { ! files.add((new URI(line.trim())).getPath()); ! } catch (URISyntaxException e1) { ! System.err.println("Skipping "+line); ! } ! } ! executeBitcollider(files); ! } catch (IOException e) { ! } catch (UnsupportedFlavorException e) { ! // TODO Auto-generated catch block ! e.printStackTrace(); ! } ! return; ! } ! } ! ! dtde.rejectDrop(); ! } ! ! public void setFmtHandlers(Collection fmtHandlers) { ! this.fmtHandlers = fmtHandlers; ! } ! ! private void updateProgress(int percent, String fileName, String message) { ! ! if (0 == percent) { ! if (null != message) { ! pbCurFile.setValue(0); ! filesSkipped++; ! lblFilesSkipped.setText(""+filesSkipped+" files skipped"); ! } else { ! pbCurFile.setValue(0); ! } ! } else if (percent <= 100) { ! pbCurFile.setValue(percent); ! if (null != message) { ! filesProcessed++; ! lblFilesProcessed.setText(""+filesProcessed+" files processed"); ! pbOverallProgress.setValue(100 * filesProcessed / filesToProcess); ! } ! } ! } ! ! public void progress(final int percent, final String fileName, final String message) { ! ! if (SwingUtilities.isEventDispatchThread()) { ! updateProgress(percent, fileName, message); ! } else { ! try { ! SwingUtilities.invokeAndWait(new Runnable() { ! ! public void run() { ! updateProgress(percent, fileName, message); ! } ! ! }); ! } catch (Exception e) { ! } ! } ! ! } ! ! } --- 1,481 ---- ! /* (PD) 2006 The Bitzi Corporation ! * Please see http://bitzi.com/publicdomain for more info. ! * ! * $Id$ ! */ ! package org.bitpedia.collider.ui; ! ! import java.awt.BorderLayout; ! import java.awt.datatransfer.DataFlavor; ! import java.awt.datatransfer.Transferable; ! import java.awt.datatransfer.UnsupportedFlavorException; ! import java.awt.dnd.DnDConstants; ! import java.awt.dnd.DropTarget; ! import java.awt.dnd.DropTargetDragEvent; ! import java.awt.dnd.DropTargetDropEvent; ! import java.awt.dnd.DropTargetEvent; ! import java.awt.dnd.DropTargetListener; ! import java.awt.event.ActionEvent; ! import java.awt.event.ActionListener; ! import java.io.BufferedReader; ! import java.io.File; ! import java.io.FileNotFoundException; ! import java.io.IOException; ! import java.io.PrintWriter; ! import java.io.Reader; ! import java.net.URI; ! import java.net.URISyntaxException; ! import java.net.URL; ! import java.util.ArrayList; ! import java.util.Collection; ! import java.util.LinkedList; ! import java.util.List; ! ! import javax.swing.JButton; ! import javax.swing.JCheckBox; ! import javax.swing.JFileChooser; ! import javax.swing.JFrame; ! import javax.swing.JLabel; ! import javax.swing.JOptionPane; ! import javax.swing.JPanel; ! import javax.swing.JProgressBar; ! import javax.swing.JTextArea; ! import javax.swing.Spring; ! import javax.swing.SpringLayout; ! import javax.swing.SwingConstants; ! import javax.swing.SwingUtilities; ! ! import org.bitpedia.collider.core.Bitcollider; ! import org.bitpedia.collider.core.Submission; ! ! import edu.stanford.ejalbert.BrowserLauncher; ! import edu.stanford.ejalbert.exception.BrowserLaunchingExecutionException; ! import edu.stanford.ejalbert.exception.BrowserLaunchingInitializingException; ! import edu.stanford.ejalbert.exception.UnsupportedOperatingSystemException; ! ! public class MainDialog extends JPanel implements ActionListener, ! DropTargetListener, Bitcollider.Progress { ! ! public static final int GAP = 6; ! ! private Collection fmtHandlers; ! ! private JFrame frame; ! ! private SpringLayout layout = new SpringLayout(); ! ! private JLabel lblCurFile = new JLabel("Current File:"); ! ! private JProgressBar pbCurFile = new JProgressBar(0, 100); ! ! private JLabel lblOverallProgress = new JLabel("Overall progress:"); ! ! private JProgressBar pbOverallProgress = new JProgressBar(0, 100); ! ! private JLabel lblFilesToProcess = new JLabel("0 files to process", ! SwingConstants.CENTER); ! ! private JLabel lblFilesProcessed = new JLabel("0 files processed", ! SwingConstants.CENTER); ! ! private JLabel lblFilesSkipped = new JLabel("0 files skipped", ! SwingConstants.CENTER); ! ! private JTextArea taHint = new JTextArea( ! " (1) Drag files onto this window\n" ! + " (2) The Bitcollider extracts identifiers and metadata\n" ! + " (3) Your default web browser will launch to submit the info"); ! ! private JCheckBox chbCloseWindow = new JCheckBox( ! "Close window after processing", false); ! ! private JCheckBox chbDontShowForSmall = new JCheckBox( ! "Don't show window for small files", true); ! ! private JButton btnAbout = new JButton("About"); ! ! private JButton btnBrowse = new JButton("Browse"); ! ! private JButton btnClose = new JButton("Close"); ! ! private Spring sprPnlWidth = new WidthSpring(this); ! ! private JFileChooser fileChooser = new JFileChooser(); ! ! private int filesSkipped = 0; ! ! private int filesProcessed = 0; ! ! private int filesToProcess = 0; ! ! private boolean noSubmitting = false; ! ! private String alternateUrl; ! ! private boolean md5 = false; ! ! private boolean crc32 = false; ! ! public MainDialog(JFrame frame) { ! ! this.frame = frame; ! ! fileChooser.setMultiSelectionEnabled(true); ! ! setLayout(layout); ! ! add(lblCurFile); ! layout.putConstraint(SpringLayout.NORTH, lblCurFile, GAP, ! SpringLayout.NORTH, this); ! layout.putConstraint(SpringLayout.WEST, lblCurFile, GAP, ! SpringLayout.WEST, this); ! ! add(pbCurFile); ! layout.putConstraint(SpringLayout.EAST, pbCurFile, -GAP, ! SpringLayout.EAST, this); ! layout.putConstraint(SpringLayout.WEST, pbCurFile, GAP, ! SpringLayout.WEST, this); ! layout.putConstraint(SpringLayout.NORTH, pbCurFile, GAP, ! SpringLayout.SOUTH, lblCurFile); ! ! add(lblOverallProgress); ! layout.putConstraint(SpringLayout.NORTH, lblOverallProgress, GAP, ! SpringLayout.SOUTH, pbCurFile); ! layout.putConstraint(SpringLayout.WEST, lblOverallProgress, GAP, ! SpringLayout.WEST, this); ! ! add(pbOverallProgress); ! layout.putConstraint(SpringLayout.EAST, pbOverallProgress, -GAP, ! SpringLayout.EAST, this); ! layout.putConstraint(SpringLayout.WEST, pbOverallProgress, GAP, ! SpringLayout.WEST, this); ! layout.putConstraint(SpringLayout.NORTH, pbOverallProgress, GAP, ! SpringLayout.SOUTH, lblOverallProgress); ! ! Spring lblWidth = Spring.scale(Spring.sum(sprPnlWidth, Spring ! .constant(-4 * GAP)), 1f / 3f); ! ! add(lblFilesToProcess); ! layout.putConstraint(SpringLayout.NORTH, lblFilesToProcess, GAP, ! SpringLayout.SOUTH, pbOverallProgress); ! layout.putConstraint(SpringLayout.WEST, lblFilesToProcess, GAP, ! SpringLayout.WEST, this); ! layout.getConstraints(lblFilesToProcess).setWidth(lblWidth); ! ! add(lblFilesProcessed); ! layout.putConstraint(SpringLayout.NORTH, lblFilesProcessed, GAP, ! SpringLayout.SOUTH, pbOverallProgress); ! layout.putConstraint(SpringLayout.WEST, lblFilesProcessed, GAP, ! SpringLayout.EAST, lblFilesToProcess); ! layout.getConstraints(lblFilesProcessed).setWidth(lblWidth); ! ! add(lblFilesSkipped); ! layout.putConstraint(SpringLayout.EAST, lblFilesSkipped, -GAP, ! SpringLayout.EAST, this); ! layout.putConstraint(SpringLayout.WEST, lblFilesSkipped, GAP, ! SpringLayout.EAST, lblFilesProcessed); ! layout.putConstraint(SpringLayout.NORTH, lblFilesSkipped, GAP, ! SpringLayout.SOUTH, pbOverallProgress); ! layout.getConstraints(lblFilesSkipped).setWidth(lblWidth); ! ! add(taHint); ! taHint.setEditable(false); ! taHint.setFocusable(false); ! taHint.setBackground(this.getBackground()); ! layout.putConstraint(SpringLayout.EAST, taHint, -GAP, ! SpringLayout.EAST, this); ! layout.putConstraint(SpringLayout.WEST, taHint, GAP, SpringLayout.WEST, ! this); ! layout.putConstraint(SpringLayout.NORTH, taHint, GAP, ! SpringLayout.SOUTH, lblFilesToProcess); ! ! add(chbCloseWindow); ! layout.putConstraint(SpringLayout.NORTH, chbCloseWindow, GAP, ! SpringLayout.SOUTH, taHint); ! layout.putConstraint(SpringLayout.WEST, chbCloseWindow, GAP, ! SpringLayout.WEST, this); ! ! add(chbDontShowForSmall); ! layout.putConstraint(SpringLayout.NORTH, chbDontShowForSmall, GAP, ! SpringLayout.SOUTH, chbCloseWindow); ! layout.putConstraint(SpringLayout.WEST, chbDontShowForSmall, GAP, ! SpringLayout.WEST, this); ! ! Spring btnWidth = Spring.scale(Spring.sum(sprPnlWidth, Spring ! .constant(-4 * GAP)), 1f / 3f); ! ! add(btnAbout); ! btnAbout.addActionListener(this); ! layout.putConstraint(SpringLayout.NORTH, btnAbout, GAP, ! SpringLayout.SOUTH, chbCloseWindow); ! layout.putConstraint(SpringLayout.WEST, btnAbout, GAP, ! SpringLayout.WEST, this); ! layout.putConstraint(SpringLayout.SOUTH, btnAbout, -GAP, ! SpringLayout.SOUTH, this); ! layout.getConstraints(btnAbout).setWidth(btnWidth); ! ! add(btnBrowse); ! btnBrowse.addActionListener(this); ! layout.putConstraint(SpringLayout.NORTH, btnBrowse, GAP, ! SpringLayout.SOUTH, chbCloseWindow); ! layout.putConstraint(SpringLayout.WEST, btnBrowse, GAP, ! SpringLayout.EAST, btnAbout); ! layout.putConstraint(SpringLayout.SOUTH, btnBrowse, -GAP, ! SpringLayout.SOUTH, this); ! layout.getConstraints(btnBrowse).setWidth(btnWidth); ! ! add(btnClose); ! btnClose.addActionListener(this); ! layout.putConstraint(SpringLayout.EAST, btnClose, -GAP, ! SpringLayout.EAST, this); ! layout.putConstraint(SpringLayout.NORTH, btnClose, GAP, ! SpringLayout.SOUTH, chbCloseWindow); ! layout.putConstraint(SpringLayout.WEST, btnClose, GAP, ! SpringLayout.EAST, btnBrowse); ! layout.putConstraint(SpringLayout.SOUTH, btnClose, -GAP, ! SpringLayout.SOUTH, this); ! layout.getConstraints(btnClose).setWidth(btnWidth); ! ! new DropTarget(this, this); ! new DropTarget(taHint, this); ! } ! ! public void configure(boolean noSubmitting, String alternateUrl, boolean md5, boolean crc32) { ! ! this.noSubmitting = noSubmitting; ! this.alternateUrl = alternateUrl; ! this.md5 = md5; ! this.crc32 = crc32; ! } ! ! public static void main(String[] args) { ! ! JFrame frame = new JFrame("jBitcollider"); ! frame.getContentPane().setLayout(new BorderLayout()); ! frame.getContentPane().add("Center", new MainDialog(frame)); ! frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); ! frame.setSize(450, 300); ! frame.setResizable(false); ! frame.setLocationRelativeTo(null); ! frame.setVisible(true); ! } ! ! public void actionPerformed(ActionEvent event) { ! ! if (event.getSource() == btnAbout) { ! JOptionPane ! .showMessageDialog( ! null, ! "jBitcollider 0.1.0 \n" ! + "(PD) 2006 The Bitzi Corporation\n\n" ! + "For more information about the jBitcollider and Bitzi's Free\n" ! + "Universal Media Catalog , please visit http://bitzi.com", ! "About", JOptionPane.INFORMATION_MESSAGE); ! } else if (event.getSource() == btnBrowse) { ! ! int ret = fileChooser.showOpenDialog(frame); ! if(ret == JFileChooser.APPROVE_OPTION) { ! File[] selFiles = fileChooser.getSelectedFiles(); ! List files = new LinkedList(); ! for (int i = 0; i < selFiles.length; i++) { ! files.add(selFiles[i].getPath()); ! } ! executeBitcollider(files); ! } ! } else if (event.getSource() == btnClose) { ! System.exit(0); ! } ! ! } ! ! public void setSize(int width, int height) { ! super.setSize(width, height); ! ! System.out.println("setSize: " + width + ", " + height); ! } ! ! private void processDtde(DropTargetDragEvent dtde) { ! ! DataFlavor[] flavors = dtde.getTransferable().getTransferDataFlavors(); ! for (int i = 0; i < flavors.length; i++) { ! if (flavors[i].isFlavorJavaFileListType()) { ! dtde.acceptDrag(DnDConstants.ACTION_MOVE); ! return; ! } else if (flavors[i].getMimeType().startsWith("text/uri-list") ! && flavors[i].getRepresentationClass() == Reader.class) { ! dtde.acceptDrag(DnDConstants.ACTION_MOVE); ! return; ! } ! } ! ! dtde.rejectDrag(); ! } ! ! public void dragEnter(DropTargetDragEvent dtde) { ! ! processDtde(dtde); ! } ! ! public void dragOver(DropTargetDragEvent dtde) { ! ! processDtde(dtde); ! } ! ! public void dropActionChanged(DropTargetDragEvent dtde) { ! ! processDtde(dtde); ! } ! ! public void dragExit(DropTargetEvent dtde) { ! } ! ! private void executeBitcollider(final List files) { ! ! final Bitcollider bc = new Bitcollider(fmtHandlers); ! bc.setCalcCrc32(crc32); ! bc.setCalcMd5(md5); ! bc.setPreview(true); ! Submission prevSub = bc.generateSubmission(files, null, true); ! ! filesToProcess = prevSub.getNumBitprints(); ! filesProcessed = 0; ! lblFilesToProcess.setText(""+filesToProcess+" files to process"); ! ! Thread bt = new Thread(new Runnable() { ! ! public void run() { ! ! try { ! bc.setPreview(false); ! bc.setProgress(MainDialog.this); ! Submission submission = bc.generateSubmission(files, null, ! true); ! String tmpdir = System.getProperty("java.io.tmpdir"); ! String sep = System.getProperty("file.separator"); ! if ((null != tmpdir) && (!"".equals(tmpdir)) && (!tmpdir.endsWith(sep))) { ! tmpdir = tmpdir + sep; ! } ! String htmlFileName = tmpdir + "bitprint.html"; ! PrintWriter pw = new PrintWriter(htmlFileName); ! try { ! submission.setAutoSubmit(!noSubmitting); ! submission.makeHtml(pw, alternateUrl); ! } finally { ! pw.close(); ! } ! ! BrowserLauncher bl = new BrowserLauncher(null); ! bl.openURLinBrowser("file://localhost/"+htmlFileName); ! ! SwingUtilities.invokeLater(new Runnable() { ! ! public void run() { ! ! pbCurFile.setValue(0); ! pbOverallProgress.setValue(0); ! lblFilesToProcess.setText("0 files to process"); ! ! } ! ! }); ! ! } catch (FileNotFoundException e) { ! } catch (BrowserLaunchingInitializingException e) { ! } catch (UnsupportedOperatingSystemException e) { ! } catch (BrowserLaunchingExecutionException e) { ! } ! } ! ! }); ! ! bt.start(); ! ! } ! ! public void drop(DropTargetDropEvent dtde) { ! ! DataFlavor[] flavors = dtde.getTransferable().getTransferDataFlavors(); ! Transferable tr = dtde.getTransferable(); ! for (int i = 0; i < flavors.length; i++) { ! if (flavors[i].isFlavorJavaFileListType()) { ! dtde.acceptDrop(DnDConstants.ACTION_MOVE); ! try { ! List files = (List) tr.getTransferData(flavors[i]); ! executeBitcollider(files); ! } catch (UnsupportedFlavorException ufe) { ! } catch (IOException e) { ! } ! return; ! } else if (flavors[i].getMimeType().startsWith("text/uri-list") ! && flavors[i].getRepresentationClass() == Reader.class) { ! dtde.acceptDrop(DnDConstants.ACTION_MOVE); ! try { ! BufferedReader reader = new BufferedReader((Reader)tr.getTransferData(flavors[i])); ! String line; ! List files = new ArrayList(); ! while((line = reader.readLine()) != null) { ! try { ! files.add((new URI(line.trim())).getPath()); ! } catch (URISyntaxException e1) { ! System.err.println("Skipping "+line); ! } ! } ! executeBitcollider(files); ! } catch (IOException e) { ! } catch (UnsupportedFlavorException e) { ! // TODO Auto-generated catch block ! e.printStackTrace(); ! } ! return; ! } ! } ! ! dtde.rejectDrop(); ! } ! ! public void setFmtHandlers(Collection fmtHandlers) { ! this.fmtHandlers = fmtHandlers; ! } ! ! private void updateProgress(int percent, String fileName, String message) { ! ! if (0 == percent) { ! if (null != message) { ! pbCurFile.setValue(0); ! filesSkipped++; ! lblFilesSkipped.setText(""+filesSkipped+" files skipped"); ! } else { ! pbCurFile.setValue(0); ! } ! } else if (percent <= 100) { ! pbCurFile.setValue(percent); ! if (null != message) { ! filesProcessed++; ! assert(filesProcessed <= filesToProcess) : "Files Processed: "+filesProcessed+" Files to Process: "+ filesToProcess; ! lblFilesProcessed.setText(""+filesProcessed+" files processed"); ! pbOverallProgress.setValue(100 * filesProcessed / filesToProcess); ! } ! } ! } ! ! public void progress(final int percent, final String fileName, final String message) { ! ! if (SwingUtilities.isEventDispatchThread()) { ! updateProgress(percent, fileName, message); ! } else { ! try { ! SwingUtilities.invokeAndWait(new Runnable() { ! ! public void run() { ! updateProgress(percent, fileName, message); ! } ! ! }); ! } catch (Exception e) { ! e.printStackTrace(); ! } ! } ! ! } ! ! } |
From: Gordon M. <go...@us...> - 2006-07-14 07:37:42
|
Update of /cvsroot/bitcollider/jbitcollider In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv14603 Modified Files: README.txt Log Message: improved, matches http://bitzi.com/bitcollider/java Index: README.txt =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/README.txt,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** README.txt 13 Jul 2006 07:11:38 -0000 1.1 --- README.txt 14 Jul 2006 07:37:39 -0000 1.2 *************** *** 1,38 **** JBITCOLLIDER: Java Bitcollider ! v0.8 Preview Release July 13, 2006 ! This is a preview release for advanced users. If you have not previously installed Java and launched standalone Java applications from the command- ! line (and perhaps even if you have), you may run into problems using this ! version. ! REQUIREMENTS ! You must already have Java 5 (also known as Java 1.5) installed. It can ! be obtained from http://java.com if necessary. ! ADVANTAGES ! Compared to the Windows Bitcollider and Linux/Unix command-line Bitcollider, ! the Java Bitcollider can handle files larger than 2GB in size, and provides ! a graphical interface and drag-and-drop file analysis for the first time on ! Linux/Unix and Mac systems (as well as any other system for which Java 5 is ! available). ! USAGE ! Execute the appropriate run script (run.bat or run.sh) for your system. To analyze files, either drag them from your desktop and drop onto the jBitcollider window, or click the 'browse' button and use the file chooser. ! BUGS ! Please report bugs at the Sourceforge Bitcollider project bug tracker: http://sourceforge.net/tracker/?group_id=21211&atid=121211 ! Use the category 'jCollider' and provide a clear explanation of what behavior you expected, what buggy behavior you saw instead, and anything you tried to ! resolve the issue. \ No newline at end of file --- 1,63 ---- JBITCOLLIDER: Java Bitcollider ! v0.8 Preview Release July 14, 2006 ! This is a preview release for advanced users. (If you have not previously installed Java and launched standalone Java applications from the command- ! line -- and perhaps even if you have -- you may run into problems using ! this version. ! ADVANTAGES ! * Processes files larger than 2GB in size. ! * Offers the graphical interface, and drag-and-drop Bitcolliding, ! on non-Windows systems for the first time. ! * Improves reliability of submission via browser ! ! LIMITATIONS ! ! * No installer. ! * No Windows 'shell' integration. (No right-click option for "Bitzi ! Lookup".) ! REQUIREMENTS ! ! You must already have Java 5 (also known as Java 1.5) installed. You can ! check if Java is installed by executing 'java -version' at a command line. ! (The applet at <http://www.java.com/en/download/help/testvm.xml> may also ! help, though it only checks the Java support available to your browser, ! and jBitcollider runs outside the browser.) ! Java be obtained from http://java.com if necessary. ! USAGE ! Expand the downloaded jBitcollider-0.8.zip file. In the resulting directory, ! execute the appropriate run script (run.bat or run.sh) for your system. To analyze files, either drag them from your desktop and drop onto the jBitcollider window, or click the 'browse' button and use the file chooser. + Results will be submitted to Bitzi via your default web browser. ! BUG REPORTS & DISCUSSION ! Please report bugs via: + Sourceforge Bitcollider project bug tracker http://sourceforge.net/tracker/?group_id=21211&atid=121211 ! Use the category 'jCollider' and provide a clear explanation of what behavior you expected, what buggy behavior you saw instead, and anything you tried to ! resolve the issue. ! ! jBitcollider may be discussed at: ! ! Bitpedia project discussion list ! http://bitzi.com/bitpedia/bitpedia-l ! ! LICENSE ! ! Like the original Bitcollider, the source code for jBitcollider is released ! into the public domain, free for all uses. See the file COPYING for details. ! (jBitcollider does include 3rd-party open-source-licensed libraries that ! remain subject to their respective licenses.) \ No newline at end of file |
From: Gordon M. <go...@us...> - 2006-07-14 06:57:10
|
Update of /cvsroot/bitcollider/jbitcollider In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv31573 Added Files: COPYING Log Message: update public-domain statement --- NEW FILE: COPYING --- /* (PD) 2006 The Bitzi Corporation * * 1. Authorship. This work and others bearing the above * label were created by, or on behalf of, the Bitzi * Corporation. Often other public domain material by * other authors is incorporated; this should be clear * from notations in the source code. If other non- * public-domain code or libraries are included, this is * is done under those works' respective licenses. * * 2. Release. The Bitzi Corporation places its portion * of these labelled works into the public domain, * disclaiming all rights granted us by copyright law. * * Bitzi places no restrictions on your freedom to copy, * use, redistribute and modify this work, though you * should be aware of points (3), (4), and (5) below. * * 3. Trademark Advisory. The Bitzi Corporation reserves * all rights with regard to any of its trademarks which * may appear herein, such as "Bitzi", "Bitcollider", or * "Bitpedia". Please take care that your uses of this * work do not infringe on our trademarks or imply our * endorsement. For example, you should change labels * and identifier strings in your derivative works where * appropriate. * * 4. Licensed portions. Some code and libraries may be * incorporated in this work in accordance with the * licenses offered by their respective rightsholders. * Further copying, use, redistribution and modification * of these third-party portions remains subject to * their original licenses. * * 5. Disclaimer. THIS SOFTWARE IS PROVIDED BY THE AUTHOR * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR * TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * * Please see http://bitzi.com/publicdomain or write * in...@bi... for more info. */ |
From: Gordon M. <go...@us...> - 2006-07-14 04:58:43
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.vorbis/src/org/bitpedia/collider/vorbis In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv18620/plugins/org.bitpedia.collider.vorbis/src/org/bitpedia/collider/vorbis Modified Files: VorbisFormatHandler.java Log Message: Add Bitzi public-domain notice atop Java sources. Index: VorbisFormatHandler.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.vorbis/src/org/bitpedia/collider/vorbis/VorbisFormatHandler.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** VorbisFormatHandler.java 14 Apr 2006 07:40:12 -0000 1.1 --- VorbisFormatHandler.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.vorbis; |
From: Gordon M. <go...@us...> - 2006-07-14 04:58:43
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/util In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv18620/plugins/org.bitpedia.collider.core/src/org/bitpedia/util Modified Files: Base32.java ArrayUtils.java Log Message: Add Bitzi public-domain notice atop Java sources. Index: Base32.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/util/Base32.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** Base32.java 14 Apr 2006 07:40:12 -0000 1.1 --- Base32.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,5 **** ! /* Base32.java ! * (PD) 2003 Bitzi */ package org.bitpedia.util; --- 1,8 ---- ! /* (PD) 2006 The Bitzi Corporation ! * Please see http://bitzi.com/publicdomain for more info. ! * ! * $Id$ */ + package org.bitpedia.util; Index: ArrayUtils.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/util/ArrayUtils.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** ArrayUtils.java 15 Apr 2006 05:42:34 -0000 1.1 --- ArrayUtils.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.util; |
From: Gordon M. <go...@us...> - 2006-07-14 04:58:43
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.image/src/org/bitpedia/collider/image In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv18620/plugins/org.bitpedia.collider.image/src/org/bitpedia/collider/image Modified Files: ImageFormatHandler.java Log Message: Add Bitzi public-domain notice atop Java sources. Index: ImageFormatHandler.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.image/src/org/bitpedia/collider/image/ImageFormatHandler.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** ImageFormatHandler.java 14 Apr 2006 07:40:13 -0000 1.1 --- ImageFormatHandler.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.image; |
From: Gordon M. <go...@us...> - 2006-07-14 04:58:42
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv18620/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core Modified Files: Submission.java Id3Handler.java Mp3Handler.java FtuuHandler.java Bitcollider.java FormatHandler.java KzTreeHandler.java Ed2Handler.java Bitprint.java Md4Handler.java Md5Handler.java Log Message: Add Bitzi public-domain notice atop Java sources. Index: Submission.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core/Submission.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** Submission.java 15 Apr 2006 05:43:45 -0000 1.2 --- Submission.java 14 Jul 2006 04:58:39 -0000 1.3 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.core; Index: Id3Handler.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core/Id3Handler.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** Id3Handler.java 14 Apr 2006 07:40:12 -0000 1.1 --- Id3Handler.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.core; Index: Mp3Handler.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core/Mp3Handler.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** Mp3Handler.java 14 Apr 2006 07:40:12 -0000 1.1 --- Mp3Handler.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.core; Index: FtuuHandler.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core/FtuuHandler.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** FtuuHandler.java 14 Apr 2006 07:40:12 -0000 1.1 --- FtuuHandler.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.core; Index: Bitcollider.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core/Bitcollider.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** Bitcollider.java 14 Apr 2006 07:40:12 -0000 1.1 --- Bitcollider.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.core; Index: FormatHandler.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core/FormatHandler.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** FormatHandler.java 14 Apr 2006 07:40:12 -0000 1.1 --- FormatHandler.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.core; Index: KzTreeHandler.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core/KzTreeHandler.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** KzTreeHandler.java 14 Apr 2006 07:40:12 -0000 1.1 --- KzTreeHandler.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.core; Index: Ed2Handler.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core/Ed2Handler.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** Ed2Handler.java 14 Apr 2006 07:40:12 -0000 1.1 --- Ed2Handler.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.core; Index: Bitprint.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core/Bitprint.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** Bitprint.java 14 Apr 2006 07:40:12 -0000 1.1 --- Bitprint.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.core; Index: Md4Handler.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core/Md4Handler.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** Md4Handler.java 14 Apr 2006 07:40:12 -0000 1.1 --- Md4Handler.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.core; Index: Md5Handler.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core/Md5Handler.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** Md5Handler.java 14 Apr 2006 07:40:12 -0000 1.1 --- Md5Handler.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.core; |
From: Gordon M. <go...@us...> - 2006-07-14 04:58:42
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.ui/src/org/bitpedia/collider/ui In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv18620/plugins/org.bitpedia.collider.ui/src/org/bitpedia/collider/ui Modified Files: ColliderUtils.java AppPlugin.java MainDialog.java WidthSpring.java Log Message: Add Bitzi public-domain notice atop Java sources. Index: ColliderUtils.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.ui/src/org/bitpedia/collider/ui/ColliderUtils.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** ColliderUtils.java 14 Apr 2006 07:40:12 -0000 1.1 --- ColliderUtils.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.ui; Index: AppPlugin.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.ui/src/org/bitpedia/collider/ui/AppPlugin.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** AppPlugin.java 14 Apr 2006 07:40:12 -0000 1.1 --- AppPlugin.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.ui; Index: MainDialog.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.ui/src/org/bitpedia/collider/ui/MainDialog.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** MainDialog.java 15 Apr 2006 05:45:49 -0000 1.2 --- MainDialog.java 14 Jul 2006 04:58:39 -0000 1.3 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.ui; Index: WidthSpring.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.ui/src/org/bitpedia/collider/ui/WidthSpring.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** WidthSpring.java 14 Apr 2006 07:40:12 -0000 1.1 --- WidthSpring.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.ui; |
From: Gordon M. <go...@us...> - 2006-07-14 04:58:42
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.video/src/org/bitpedia/collider/video In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv18620/plugins/org.bitpedia.collider.video/src/org/bitpedia/collider/video Modified Files: VideoFormatHandler.java VideoUtils.java AviFormat.java QuickTimeFormat.java MpegFormat.java Log Message: Add Bitzi public-domain notice atop Java sources. Index: VideoFormatHandler.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.video/src/org/bitpedia/collider/video/VideoFormatHandler.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** VideoFormatHandler.java 14 Apr 2006 07:40:12 -0000 1.1 --- VideoFormatHandler.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.video; Index: VideoUtils.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.video/src/org/bitpedia/collider/video/VideoUtils.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** VideoUtils.java 14 Apr 2006 07:40:12 -0000 1.1 --- VideoUtils.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.video; Index: AviFormat.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.video/src/org/bitpedia/collider/video/AviFormat.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** AviFormat.java 14 Apr 2006 07:40:12 -0000 1.1 --- AviFormat.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.video; Index: QuickTimeFormat.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.video/src/org/bitpedia/collider/video/QuickTimeFormat.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** QuickTimeFormat.java 14 Apr 2006 07:40:12 -0000 1.1 --- QuickTimeFormat.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.video; Index: MpegFormat.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.video/src/org/bitpedia/collider/video/MpegFormat.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** MpegFormat.java 14 Apr 2006 07:40:12 -0000 1.1 --- MpegFormat.java 14 Jul 2006 04:58:39 -0000 1.2 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.video; |
From: Gordon M. <go...@us...> - 2006-07-14 04:58:42
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.wav/src/org/bitpedia/collider/wav In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv18620/plugins/org.bitpedia.collider.wav/src/org/bitpedia/collider/wav Modified Files: WavFormatHandler.java Log Message: Add Bitzi public-domain notice atop Java sources. Index: WavFormatHandler.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.wav/src/org/bitpedia/collider/wav/WavFormatHandler.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** WavFormatHandler.java 15 Apr 2006 05:43:45 -0000 1.2 --- WavFormatHandler.java 14 Jul 2006 04:58:39 -0000 1.3 *************** *** 1,2 **** --- 1,7 ---- + /* (PD) 2006 The Bitzi Corporation + * Please see http://bitzi.com/publicdomain for more info. + * + * $Id$ + */ package org.bitpedia.collider.wav; |
From: Gordon M. <go...@us...> - 2006-07-13 07:11:41
|
Update of /cvsroot/bitcollider/jbitcollider In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv14995 Added Files: README.txt Log Message: * README.txt minimal readme for "v0.8 preview release" --- NEW FILE: README.txt --- JBITCOLLIDER: Java Bitcollider v0.8 Preview Release July 13, 2006 This is a preview release for advanced users. If you have not previously installed Java and launched standalone Java applications from the command- line (and perhaps even if you have), you may run into problems using this version. REQUIREMENTS You must already have Java 5 (also known as Java 1.5) installed. It can be obtained from http://java.com if necessary. ADVANTAGES Compared to the Windows Bitcollider and Linux/Unix command-line Bitcollider, the Java Bitcollider can handle files larger than 2GB in size, and provides a graphical interface and drag-and-drop file analysis for the first time on Linux/Unix and Mac systems (as well as any other system for which Java 5 is available). USAGE Execute the appropriate run script (run.bat or run.sh) for your system. To analyze files, either drag them from your desktop and drop onto the jBitcollider window, or click the 'browse' button and use the file chooser. BUGS Please report bugs at the Sourceforge Bitcollider project bug tracker: http://sourceforge.net/tracker/?group_id=21211&atid=121211 Use the category 'jCollider' and provide a clear explanation of what behavior you expected, what buggy behavior you saw instead, and anything you tried to resolve the issue. |
From: Gordon M. <go...@us...> - 2006-07-12 06:43:12
|
Update of /cvsroot/bitcollider/jbitcollider In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv30462 Added Files: run.sh Log Message: * run.sh launch script for linux --- NEW FILE: run.sh --- #!/usr/bin/env sh java -cp lib/jpf-boot.jar org.java.plugin.boot.Boot %1 %2 %3 %4 %5 %6 %7 %8 %9 |
From: Gordon M. <go...@us...> - 2006-04-15 05:45:52
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.ui/src/org/bitpedia/collider/ui In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32582/plugins/org.bitpedia.collider.ui/src/org/bitpedia/collider/ui Modified Files: MainDialog.java Log Message: * MainDialog.java bitprint.htmL remove unused method improve extraction of path to handle spaces (using URI instead of URL) Index: MainDialog.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.ui/src/org/bitpedia/collider/ui/MainDialog.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** MainDialog.java 14 Apr 2006 07:40:12 -0000 1.1 --- MainDialog.java 15 Apr 2006 05:45:49 -0000 1.2 *************** *** 19,22 **** --- 19,24 ---- import java.io.PrintWriter; import java.io.Reader; + import java.net.URI; + import java.net.URISyntaxException; import java.net.URL; import java.util.ArrayList; *************** *** 348,352 **** tmpdir = tmpdir + sep; } ! String htmlFileName = tmpdir + "bitprint.htm"; PrintWriter pw = new PrintWriter(htmlFileName); try { --- 350,354 ---- tmpdir = tmpdir + sep; } ! String htmlFileName = tmpdir + "bitprint.html"; PrintWriter pw = new PrintWriter(htmlFileName); try { *************** *** 357,362 **** } - // BrowserControl.displayURL("file://localhost/" - // + htmlFileName); BrowserLauncher bl = new BrowserLauncher(null); bl.openURLinBrowser("file://localhost/"+htmlFileName); --- 359,362 ---- *************** *** 386,402 **** } - - public String filenameFromUrl(URL url) { - String filename = url.getFile(); - int lastSlash = url.getPath().lastIndexOf("/"); - if(lastSlash==filename.length()) { - filename = filename.substring(0,filename.length()-1); - lastSlash = url.getPath().lastIndexOf("/"); - } - if(lastSlash>0) { - filename = filename.substring(lastSlash+1); - } - return filename; - } public void drop(DropTargetDropEvent dtde) { --- 386,389 ---- *************** *** 422,426 **** List files = new ArrayList(); while((line = reader.readLine()) != null) { ! files.add((new URL(line.trim())).getFile()); } executeBitcollider(files); --- 409,417 ---- List files = new ArrayList(); while((line = reader.readLine()) != null) { ! try { ! files.add((new URI(line.trim())).getPath()); ! } catch (URISyntaxException e1) { ! System.err.println("Skipping "+line); ! } } executeBitcollider(files); |
From: Gordon M. <go...@us...> - 2006-04-15 05:43:48
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31291/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core Modified Files: Submission.java Log Message: Update import for relocated class Index: Submission.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core/Submission.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** Submission.java 14 Apr 2006 07:40:12 -0000 1.1 --- Submission.java 15 Apr 2006 05:43:45 -0000 1.2 *************** *** 11,14 **** --- 11,15 ---- import java.util.Map; + import org.bitpedia.util.ArrayUtils; import org.bitpedia.util.Base32; |
From: Gordon M. <go...@us...> - 2006-04-15 05:43:48
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.wav/src/org/bitpedia/collider/wav In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31291/plugins/org.bitpedia.collider.wav/src/org/bitpedia/collider/wav Modified Files: WavFormatHandler.java Log Message: Update import for relocated class Index: WavFormatHandler.java =================================================================== RCS file: /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.wav/src/org/bitpedia/collider/wav/WavFormatHandler.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** WavFormatHandler.java 14 Apr 2006 07:40:13 -0000 1.1 --- WavFormatHandler.java 15 Apr 2006 05:43:45 -0000 1.2 *************** *** 8,14 **** import org.bitpedia.collider.core.FormatHandler; import org.bitpedia.util.Sha1; - import org.bitpedia.collider.core.ArrayUtils; public class WavFormatHandler implements FormatHandler { --- 8,14 ---- import org.bitpedia.collider.core.FormatHandler; + import org.bitpedia.util.ArrayUtils; import org.bitpedia.util.Sha1; public class WavFormatHandler implements FormatHandler { |
From: Gordon M. <go...@us...> - 2006-04-15 05:42:52
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30693/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core Removed Files: Sha.java Log Message: Remove unused classes --- Sha.java DELETED --- |
From: Gordon M. <go...@us...> - 2006-04-15 05:42:52
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.ui/src/org/bitpedia/collider/ui In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30693/plugins/org.bitpedia.collider.ui/src/org/bitpedia/collider/ui Removed Files: BrowserControl.java Log Message: Remove unused classes --- BrowserControl.java DELETED --- |
From: Gordon M. <go...@us...> - 2006-04-15 05:42:41
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30556/plugins/org.bitpedia.collider.core/src/org/bitpedia/collider/core Removed Files: ArrayUtils.java Log Message: Refactor * ArrayUtils.java remove unused method; move to util package --- ArrayUtils.java DELETED --- |
From: Gordon M. <go...@us...> - 2006-04-15 05:42:40
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core/src/org/bitpedia/util In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30556/plugins/org.bitpedia.collider.core/src/org/bitpedia/util Added Files: ArrayUtils.java Log Message: Refactor * ArrayUtils.java remove unused method; move to util package --- NEW FILE: ArrayUtils.java --- package org.bitpedia.util; public class ArrayUtils { public static String byteToHex(byte b) { return Integer.toString((b & 0xFF) + 0x100, 16).substring(1); } public static String byteArrayToHex(byte[] b, int offset, int len) { StringBuffer buf = new StringBuffer(); for (int i = offset; i < offset+len; i++) { buf.append(byteToHex(b[i])); } return buf.toString(); } } |
From: Gordon M. <go...@us...> - 2006-04-14 07:40:21
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.wav/src/org/bitpedia/collider/wav In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20753/plugins/org.bitpedia.collider.wav/src/org/bitpedia/collider/wav Added Files: WavFormatHandler.java Log Message: initial commit from code drop of april 12 --- NEW FILE: WavFormatHandler.java --- package org.bitpedia.collider.wav; import java.io.FileInputStream; import java.nio.ByteBuffer; import java.nio.ByteOrder; import java.util.HashMap; import java.util.Map; import org.bitpedia.collider.core.FormatHandler; import org.bitpedia.util.Sha1; import org.bitpedia.collider.core.ArrayUtils; public class WavFormatHandler implements FormatHandler { private String errorString; private Sha1 audioSha1; private boolean stereo; private int sampleRate, channels, sampleSize; private int dataLen; private int samples; private int bytesProcessed; public boolean supportsExtension(String ext) { return "wav".equalsIgnoreCase(ext); } public boolean supportsMemAnalyze() { return true; } public boolean supportsFileAnalyze() { return false; } public void analyzeInit() { audioSha1 = new Sha1(); stereo = false; sampleRate = 0; channels = 0; sampleSize = 0; dataLen = 0; samples = 0; bytesProcessed = 0; } public void analyzeUpdate(byte[] buf, int bufLen) { if (-1 == bytesProcessed) { return; } if (0 == bytesProcessed) { if (buf[0] != 'R' || buf[1] != 'I' || buf[2] != 'F' || buf[3] != 'F' || buf[8] != 'W' || buf[9] != 'A' || buf[10] != 'V' || buf[11] != 'E' || buf[12] != 'f' || buf[13] != 'm' || buf[14] != 't' || buf[15] != ' ') { errorString = "File is not in WAV format."; bytesProcessed = -1; return; } /* * We're going to assume that we have the entire header in the first * block */ assert bufLen >= 44; ByteBuffer bbuf = ByteBuffer.wrap(buf); bbuf.order(ByteOrder.LITTLE_ENDIAN); channels = bbuf.getShort(22); sampleRate = bbuf.getInt(24); sampleSize = bbuf.getShort(34); dataLen = bbuf.getInt(40); if ((8 != sampleSize) && (16 != sampleSize)) { bytesProcessed = -1; errorString = "Invalid sample size found in wav file."; return; } samples = dataLen / (channels * (sampleSize >> 3)); audioSha1.engineUpdate(buf, 44, bufLen-44); bytesProcessed += bufLen - 44; } else { audioSha1.engineUpdate(buf, 0, bufLen); bytesProcessed += bufLen; } } public Map analyzeFinal() { if (-1 == bytesProcessed) { return null; } byte[] hash = audioSha1.engineDigest(); String value; Map attrs = new HashMap(); /* Do a quick check to see which integer math calc is appropriate */ if (0 < sampleRate) { if (samples < sampleRate) { value = Integer.toString(samples * 1000 / sampleRate); } else { value = Integer.toString((samples / sampleRate) * 1000); } attrs.put("tag.wav.duration", value); } attrs.put("tag.wav.samplerate", Integer.toString(sampleRate)); attrs.put("tag.wav.channels", Integer.toString(channels)); attrs.put("tag.wav.samplesize", Integer.toString(sampleSize)); value = ArrayUtils.byteArrayToHex(hash, 0, hash.length); attrs.put("tag.wav.audio_sha1", value); return attrs; } public static void main(String[] args) { try { FileInputStream fis = new FileInputStream( "c:\\WINDOWS\\Media\\chord.wav"); byte[] buf = new byte[44]; fis.read(buf); WavFormatHandler wfh = new WavFormatHandler(); wfh.analyzeUpdate(buf, 44); System.out.println("sampleRate: " + wfh.sampleRate + ", channels:" + wfh.channels + ", sampleSize:" + wfh.sampleSize + ", dataLen:" + wfh.dataLen); fis.close(); } catch (Exception e) { } } public Map analyzeFile(String fileName) { errorString = "analyzeFile method is not supported."; return null; } public String getError() { return errorString; } } |
From: Gordon M. <go...@us...> - 2006-04-14 07:40:21
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.vorbis In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20753/plugins/org.bitpedia.collider.vorbis Added Files: plugin.xml .cvsignore Log Message: initial commit from code drop of april 12 --- NEW FILE: plugin.xml --- <?xml version="1.0" ?> <!DOCTYPE plugin PUBLIC "-//JPF//Java Plug-in Manifest 0.4" "http://jpf.sourceforge.net/plugin_0_4.dtd"> <plugin id="org.bitpedia.collider.vorbis" version="0.0.1"> <requires> <import plugin-id="org.bitpedia.collider.core"/> </requires> <runtime> <library id="vorbis" path="bin/" type="code"> <export prefix="*"/> </library> <library id="vorbisspi" path="lib/vorbisspi1.0.2.jar" type="code"/> <library id="jorbis" path="lib/jorbis-0.0.15.jar" type="code"/> <library id="tritonus" path="lib/tritonus_share.jar" type="code"/> <library id="jogg" path="lib/jogg-0.0.7.jar" type="code"/> </runtime> <extension plugin-id="org.bitpedia.collider.core" point-id="FormatHandler" id="Vorbis"> <parameter id="class" value="org.bitpedia.collider.vorbis.VorbisFormatHandler"/> </extension> </plugin> --- NEW FILE: .cvsignore --- bin |
From: Gordon M. <go...@us...> - 2006-04-14 07:40:21
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.ui In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20753/plugins/org.bitpedia.collider.ui Added Files: .cvsignore plugin.xml Log Message: initial commit from code drop of april 12 --- NEW FILE: .cvsignore --- bin --- NEW FILE: plugin.xml --- <?xml version="1.0" ?> <!DOCTYPE plugin PUBLIC "-//JPF//Java Plug-in Manifest 0.4" "http://jpf.sourceforge.net/plugin_0_4.dtd"> <plugin id="org.bitpedia.collider.ui" version="0.0.1" class="org.bitpedia.collider.ui.AppPlugin"> <requires> <import plugin-id="org.bitpedia.collider.core"/> </requires> <runtime> <library id="ui" path="bin/" type="code"> <export prefix="*"/> </library> <library id="browserlaunch" path="lib/BrowserLauncher2-10rc4.jar" type="code"/> </runtime> </plugin> |
From: Gordon M. <go...@us...> - 2006-04-14 07:40:21
|
Update of /cvsroot/bitcollider/jbitcollider/plugins/org.bitpedia.collider.core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20753/plugins/org.bitpedia.collider.core Added Files: plugin.xml .cvsignore Log Message: initial commit from code drop of april 12 --- NEW FILE: plugin.xml --- <?xml version="1.0" ?> <!DOCTYPE plugin PUBLIC "-//JPF//Java Plug-in Manifest 0.4" "http://jpf.sourceforge.net/plugin_0_4.dtd"> <plugin id="org.bitpedia.collider.core" version="0.0.1"> <runtime> <library id="core" path="bin/" type="code"> <export prefix="*"/> </library> </runtime> <extension-point id="FormatHandler"> <parameter-def id="class"/> </extension-point> </plugin> --- NEW FILE: .cvsignore --- bin |