Skip to content

Commit

Permalink
Add arcadeitalia database
Browse files Browse the repository at this point in the history
  • Loading branch information
sselph committed Feb 5, 2017
1 parent 6671de3 commit 7db782e
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 18 deletions.
32 changes: 16 additions & 16 deletions adb/adb.go
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
package adb

import(
import (
"encoding/json"
"errors"
"fmt"
"io/ioutil"
"net/http"
"net/url"
"encoding/json"
"io/ioutil"
)

const (
baseURL = "http://adb.arcadeitalia.net"
path = "/service_scraper.php"
path = "/service_scraper.php"
)

var Source = "adb.arcadeitalia.net"
Expand All @@ -20,19 +20,19 @@ var Source = "adb.arcadeitalia.net"
var ErrNotFound = errors.New("rom not found")

type Result struct {
ID string `json:"game_name"`
Genre string `json:"genre"`
History string `json:"history"`
CopyRightLong string `json:"history_copyright_long"`
ID string `json:"game_name"`
Genre string `json:"genre"`
History string `json:"history"`
CopyRightLong string `json:"history_copyright_long"`
CopyRightShort string `json:"history_copyright_short"`
Manufacturer string `json:"manufacturer"`
Players string `json:"players"`
Name string `json:"title"`
Cabinet string `json:"url_image_cabinet"`
Snap string `json:"url_image_ingame"`
Marquee string `json:"url_image_marquee"`
Title string `json:"url_image_title"`
Year string `json:"year"`
Manufacturer string `json:"manufacturer"`
Players string `json:"players"`
Name string `json:"title"`
Cabinet string `json:"url_image_cabinet"`
Snap string `json:"url_image_ingame"`
Marquee string `json:"url_image_marquee"`
Title string `json:"url_image_title"`
Year string `json:"year"`
}

type GameResp struct {
Expand Down
4 changes: 2 additions & 2 deletions ds/adb.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@ package ds

import (
"fmt"
"path/filepath"
"regexp"
"strconv"
"path/filepath"

"github.com/sselph/scraper/adb"
)

var bioRE = regexp.MustCompile(`- (CAST|CONTRIBUTE|PORTS|SCORING|SERIES|STAFF|TECHNICAL|TRIVIA|UPDATES) -`)

// ADB is a Data Source using arcadeitalia and arcade-history.
type ADB struct {}
type ADB struct{}

// getID gets the ID for the game..
func (a *ADB) getID(p string) (string, error) {
Expand Down

0 comments on commit 7db782e

Please sign in to comment.