This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package net.libcode.www.openlibrary; | |
import java.io.BufferedReader; | |
import java.io.BufferedWriter; | |
import java.io.File; | |
import java.io.FileReader; | |
import java.io.FileWriter; | |
import java.io.IOException; | |
import org.json.simple.JSONObject; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package net.libcode.www.openlibrary; | |
import java.io.BufferedReader; | |
import java.io.File; | |
import java.io.FileReader; | |
import java.io.IOException; | |
import java.nio.charset.Charset; | |
import java.util.ArrayList; | |
import java.util.HashMap; | |
import java.util.HashSet; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package net.libcode.www.openlibrary; | |
import java.io.File; | |
import java.io.FileInputStream; | |
import java.io.FileNotFoundException; | |
import org.marc4j.MarcPermissiveStreamReader; | |
import org.marc4j.marc.Record; | |
public class OpenLibraryMarc { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'marc' | |
TAG = '856' | |
SUB = 'y' | |
STR = 'Img100' | |
REP = 'Img200' | |
count = 0 | |
w = MARC::Writer.new('dla_fixed.mrc') | |
MARC::ForgivingReader.new('records/dla.mrc').each do |r| |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'rss/2.0' | |
require 'open-uri' | |
require 'csv' | |
csv = 'libgig.csv' | |
source = 'http://publicboard.libgig.com/feeds/rss20' | |
content = '' # raw content of rss feed will be loaded here | |
open(source) do |s| content = s.read end | |
rss = RSS::Parser.parse(content, false) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# find isbn numbers with at least partial Google books embed viewer | |
require 'nokogiri' | |
require 'open-uri' | |
require 'json' | |
# load a with ISBN numbers | |
a = [] | |
g = 'http://books.google.com/books?jscmd=viewapi&bibkeys=' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'zip/zip' | |
require 'marc' | |
search = 'tower heist' | |
path = 'X:/Digital Projects/FTP files/files*/*' | |
Dir[path].each do |f| | |
if f =~ /\.zip$/ | |
Zip::ZipFile.open(f) do |zipfile| | |
zipfile.each do |entry| |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.sonomalibrary.catcher; | |
import java.io.BufferedReader; | |
import java.io.File; | |
import java.io.FileReader; | |
import java.io.IOException; | |
import java.util.ArrayList; | |
import java.util.List; | |
import org.oclc.cdm.catcherws.CatcherService; | |
import org.oclc.cdm.catcherws.Metadata; | |
import org.oclc.cdm.catcherws.MetadataWrapper; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.sonomalibrary.catcher; | |
import java.io.BufferedReader; | |
import java.io.File; | |
import java.io.FileReader; | |
import java.io.IOException; | |
import java.util.ArrayList; | |
import java.util.HashMap; | |
import java.util.List; | |
import java.util.Map; | |
import java.util.Set; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1,17c1 | |
< <?xml version="1.0"?> | |
< <!-- | |
< vim:et:ts=2:sw=2: | |
< --> | |
< <opensrf version="0.0.3"> | |
< <!-- | |
< | |
< There is one <host> entry for each server on the network. Settings for the | |
< 'default' host are used for every setting that isn't overridden within a given |