Notes
extends Item
in package
Class Notes
KNV product category 'Noten'
Table of Contents
- $api : Webservice|null
- $data : array<string|int, mixed>
- $people : array<string|int, mixed>
- Involved people (all roles)
- $available : array<string|int, mixed>
- Status codes of available products
- $errorMessages : array<string|int, mixed>
- Current KNV 'Fehlernummer' descriptions
- $identifier : string
- Product EAN/ISBN
- $olaMessages : array<string|int, mixed>
- Current KNV 'Meldenummer' descriptions
- $unavailable : array<string|int, mixed>
- Status codes of unavailable products
- __construct() : void
- Constructor
- __toString() : string
- Print author & title when casting to string
- actor() : Role
- Exports actor(s)
- age() : Value
- Exports recommended minimum age (in years)
- author() : Role
- Exports author(s)
- categories() : Value
- Exports categories
- composer() : Role
- Export composer(s)
- depth() : Value
- Exports depth (in cm)
- description() : Value
- Exports description(s)
- dimensions() : Value
- Exports dimensions (in cm)
- director() : Role
- Exports director(s)
- downloadCover() : bool
- Downloads cover images from the German National Library (DNB)
- drawer() : Role
- Exports drawer(s)
- ean() : string
- Exports European Article Number (EAN)
- editor() : Role
- Exports editor(s)
- export() : array<string|int, mixed>
- Exports all data
- getRole() : Role
- Exports people of given role
- hasDowngrade() : bool
- Checks whether product has a predecessor
- hasOlaCode() : bool
- Checks whether KNV 'Meldenummer' is present
- hasUpgrade() : bool
- Checks whether product has a successor
- height() : Value
- Exports height (in cm)
- illustrator() : Role
- Exports illustrator(s)
- isAudiobook() : bool
- Checks whether this is an audiobook
- isAvailable() : bool
- Checks whether product is available (= purchasable)
- isbn() : string
- Exports International Standard Book Number (ISBN)
- isBoardgame() : bool
- Checks whether this is a boardgame
- isBook() : bool
- Checks whether this is a book
- isCalendar() : bool
- Checks whether this is a calendar
- isEbook() : bool
- Checks whether this is an eBook
- isHardcover() : bool
- Checks whether this is a hardcover book
- isItem() : bool
- Checks whether this is an item
- isMap() : bool
- Checks whether this is a map
- isMedia() : bool
- Checks whether this is a medium
- isMovie() : bool
- Checks whether this is a movie
- isMusic() : bool
- Checks whether this is music
- isNonbook() : bool
- Checks whether this is a generic item
- isNotes() : bool
- Checks whether these are notes
- isSchoolbook() : bool
- Checks whether this is a schoolbook
- isSeries() : bool
- Checks whether product is part of (at least one) series
- isSoftcover() : bool
- Checks whether this is a softcover book
- isSoftware() : bool
- Checks whether this is software
- isSound() : bool
- Checks whether this is a sound storage medium
- isStationery() : bool
- Checks whether this is stationery
- isToy() : bool
- Checks whether this is a toy
- isUnavailable() : bool
- Checks whether product is permanently unavailable
- isVideogame() : bool
- Checks whether this is a videogame
- languages() : Value
- Exports language(s)
- narrator() : Role
- Exports narrator(s)
- ola() : Ola
- Exports OLA record
- olaCode() : string
- Exports KNV 'Meldenummer' (if present)
- olaMessage() : string
- Exports KNV 'Meldetext' (if present)
- original() : Role
- Exports original author(s
- participant() : Role
- Exports participant(s)
- people() : Roles
- Exports (just) involved people
- photographer() : Role
- Exports photographer(s)
- producer() : Role
- Exports producer(s)
- publisher() : Value
- Exports publisher(s)
- releaseYear() : Value
- Exports release year
- retailPrice() : Value
- Exports retail price (in €)
- series() : Series
- Exports series & volume(s)
- subtitle() : Value
- Exports subtitle
- title() : Value
- Exports title
- topics() : Value
- Exports topics
- translator() : Role
- Exports translator(s)
- type() : string
- Detects product type
- vat() : Value
- Exports type of value added tax (VAT)
- weight() : Value
- Exports weight (in g)
- width() : Value
- Exports width (in cm)
- buildActor() : array<string|int, mixed>
- Builds actor(s)
- buildAuthor() : array<string|int, mixed>
- Builds author(s)
- buildComposer() : array<string|int, mixed>
- Builds composer(s)
- buildDirector() : array<string|int, mixed>
- Builds director(s)
- buildDrawer() : array<string|int, mixed>
- Builds drawer(s)
- buildEditor() : array<string|int, mixed>
- Builds editor(s)
- buildIllustrator() : array<string|int, mixed>
- Builds illustrator(s)
- buildNarrator() : array<string|int, mixed>
- Builds narrator(s)
- buildOriginal() : array<string|int, mixed>
- Builds original author(s)
- buildParticipant() : array<string|int, mixed>
- Builds participant(s)
- buildPhotographer() : array<string|int, mixed>
- Builds photographer(s)
- buildProducer() : array<string|int, mixed>
- Builds producer(s)
- buildTranslator() : array<string|int, mixed>
- Builds translator(s)
- convertMM() : string
- Converts millimeters to centimeters
- getTags() : array<string|int, mixed>
- Extracts tags from raw data
- organizePeople() : array<string|int, mixed>
- Parses & organizes involved people by first & last name
- setUpPeople() : array<string|int, mixed>
- Extracts involved people from raw data
Properties
$api
public
Webservice|null
$api
= null
$data
public
array<string|int, mixed>
$data
$people
Involved people (all roles)
public
array<string|int, mixed>
$people
$available
Status codes of available products
protected
array<string|int, mixed>
$available
= ['11', '12', '15', '18', '21', '23', '25', '80', '97', '98']
Preorder always:
- 18 Wird besorgt – nicht remittierbar/nicht stornierbar
- 97 Print on Demand (ggf. mit Angabe der Lieferzeit) – nicht remittierbar/nicht stornierbar
Preorder possible:
- 11 Erscheint laut Verlag/Lieferant .../... in neuer Auflage/als Nachfolgeprodukt
- 12 Nachdruck/wird nachproduziert. Folgt laut Verlag/Lieferant .../...
- 15 Fehlt kurzfristig am Lager
- 21 Noch nicht erschienen. Erscheint laut Verlag/Lieferant ...
- 23 Titel wegen Lieferverzug des Verlags/der Verlagsauslieferung derzeit nicht lieferbar
- 25 Artikel neu aufgenommen. Noch nicht am Lager
- 80 Fehlt, da der Verlag/Lieferant derzeit nicht liefern kann
- 98 Folgt mit nächster Lieferung
$errorMessages
Current KNV 'Fehlernummer' descriptions
protected
array<string|int, mixed>
$errorMessages
= ['19003' => 'Benutzerfehler', '19004' => 'Passwortfehler', '19005' => 'Hostfehler', '19006' => 'Falsche ACT', '19007' => 'Verkehrsnummer fehlt', '19008' => 'Bestellnummer fehlt', '19009' => 'Menge fehlt', '19010' => 'Kommunikationsfehler', '19011' => 'Antwortfehler', '19012' => 'Antwortunterbrechung', '19013' => 'Timeout', '19014' => 'Busy', '19015' => 'No carrier', '19016' => 'Beeendigungsfehler', '19017' => 'Schreibfehler', '19018' => 'OLA-Konfiguration fehlt', '19031' => 'Bei einer OLA-Anfrage darf die Menge maximal 99 betragen', '19032' => 'Fehlende Referenznummer', '19033' => 'Fehlendes Bestelldatum', '19034' => 'Menge darf bei einer Onlinebestellung maximal 30000 betragen', '19040' => 'Fehler bei der TCPIP Initialisierung', '19041' => 'Fehler beim TCPIP Connect', '19050' => 'Referenznummer konnte nicht generiert werden', '19060' => 'Keine Vormerkung gefunden', '19061' => 'Storno nicht erlaubt']
$identifier
Product EAN/ISBN
protected
string
$identifier
$olaMessages
Current KNV 'Meldenummer' descriptions
protected
array<string|int, mixed>
$olaMessages
= ['7' => 'Vergriffen, keine Neuauflage, Bestellung abgelegt', '11' => 'Erscheint laut Verlag/Lieferant .../... in neuer Auflage/als Nachfolgeprodukt', '12' => 'Nachdruck/wird nachproduziert. Folgt laut Verlag/Lieferant .../...', '15' => 'Fehlt kurzfristig am Lager', '17' => 'Führen wir nicht bzw. nicht mehr', '18' => 'Wird besorgt – nicht remittierbar/nicht stornierbar', '19' => 'Ladenpreis aufgehoben. Führen wir nicht mehr', '20' => 'Noch nicht erschienen. Bestellung nicht vorgemerkt', '21' => 'Noch nicht erschienen. Erscheint laut Verlag/Lieferant ...', '22' => 'Terminauftrag, vorgemerkt', '24' => 'Erscheint nicht laut Verlag/Lieferant', '23' => 'Titel wegen Lieferverzug des Verlags/der Verlagsauslieferung derzeit nicht lieferbar', '25' => 'Artikel neu aufgenommen. Noch nicht am Lager', '27' => 'Vormerkung storniert', '28' => 'Titelnummer unbekannt', '29' => 'ISBN oder EAN unbekannt', '43' => 'Vergriffen – Neuauflage/Nachfolgeprodukt unbestimmt – Bestellung wird nicht vorgemerkt', '59' => 'Bestellung storniert', '60' => 'Indiziert. Führen wir nicht mehr', '62' => 'Artikel infolge rechtlicher Auseinandersetzungen zur Zeit nicht lieferbar. Bestellung nicht vorgemerkt', '63' => 'Versandart Stornierung', '73' => 'Fortsetzung', '80' => 'Fehlt, da der Verlag/Lieferant derzeit nicht liefern kann', '88' => 'Konditionsänderung durch den Verlag/Lieferanten. Führen wir nicht mehr', '94' => 'Wird zur Zeit nur ab Verlag/Lieferant geliefert – Bestellung nicht vorgemerkt', '97' => 'Print on Demand (ggf. mit Angabe der Lieferzeit) – nicht remittierbar/nicht stornierbar', '98' => 'Folgt mit nächster Lieferung', '99' => 'Titel hat Nachfolgetitel/-auflage']
$unavailable
Status codes of unavailable products
protected
array<string|int, mixed>
$unavailable
= ['7', '17', '19', '20', '24', '28', '29', '43', '60', '62', '88', '94', '99']
No orders possible:
- 07 Vergriffen, keine Neuauflage, Bestellung abgelegt
- 17 Führen wir nicht bzw. nicht mehr
- 19 Ladenpreis aufgehoben. Führen wir nicht mehr
- 20 Noch nicht erschienen. Bestellung nicht vorgemerkt
- 24 Erscheint nicht laut Verlag/Lieferant
- 28 Titelnummer unbekannt
- 29 ISBN oder EAN unbekannt
- 43 Vergriffen – Neuauflage/Nachfolgeprodukt unbestimmt – Bestellung wird nicht vorgemerkt
- 60 Indiziert. Führen wir nicht mehr
- 62 Artikel infolge rechtlicher Auseinandersetzungen zur Zeit nicht lieferbar. Bestellung nicht vorgemerkt
- 88 Konditionsänderung durch den Verlag/Lieferanten. Führen wir nicht mehr
- 94 Wird zur Zeit nur ab Verlag/Lieferant geliefert – Bestellung nicht vorgemerkt
- 99 Titel hat Nachfolgetitel/-auflage
Methods
__construct()
Constructor
public
__construct(array<string|int, mixed> $data[, Webservice $api = null ]) : void
Parameters
- $data : array<string|int, mixed>
-
Source data as fetched from KNV's API
- $api : Webservice = null
-
Object granting access to KNV's API
Return values
void —__toString()
Print author & title when casting to string
public
__toString() : string
Return values
string —actor()
Exports actor(s)
public
actor() : Role
Return values
Role —age()
Exports recommended minimum age (in years)
public
age() : Value
Return values
Value —author()
Exports author(s)
public
author() : Role
Return values
Role —categories()
Exports categories
public
categories() : Value
Return values
Value —composer()
Export composer(s)
public
composer() : Role
Return values
Role —depth()
Exports depth (in cm)
public
depth() : Value
Return values
Value —description()
Exports description(s)
public
description() : Value
Return values
Value —dimensions()
Exports dimensions (in cm)
public
dimensions() : Value
Examples:
- 'width'
- 'height'
- 'width x height'
- 'width x height x depth'
Return values
Value —director()
Exports director(s)
public
director() : Role
Return values
Role —downloadCover()
Downloads cover images from the German National Library (DNB)
public
downloadCover([mixed $file = null ][, string $ua = null ]) : bool
Parameters
- $file : mixed = null
-
Path to download file OR file-like object
- $ua : string = null
-
User-Agent used when downloading cover images
Return values
bool —Download status
drawer()
Exports drawer(s)
public
drawer() : Role
Return values
Role —ean()
Exports European Article Number (EAN)
public
ean() : string
Return values
string —editor()
Exports editor(s)
public
editor() : Role
Return values
Role —export()
Exports all data
public
export() : array<string|int, mixed>
Return values
array<string|int, mixed> —getRole()
Exports people of given role
public
getRole(string $role) : Role
Parameters
- $role : string
-
Role (= involvement)
Tags
Return values
Role —hasDowngrade()
Checks whether product has a predecessor
public
hasDowngrade() : bool
Return values
bool —hasOlaCode()
Checks whether KNV 'Meldenummer' is present
public
hasOlaCode() : bool
Return values
bool —hasUpgrade()
Checks whether product has a successor
public
hasUpgrade() : bool
Return values
bool —height()
Exports height (in cm)
public
height() : Value
Return values
Value —illustrator()
Exports illustrator(s)
public
illustrator() : Role
Return values
Role —isAudiobook()
Checks whether this is an audiobook
public
isAudiobook() : bool
Return values
bool —isAvailable()
Checks whether product is available (= purchasable)
public
isAvailable() : bool
Return values
bool —isbn()
Exports International Standard Book Number (ISBN)
public
isbn() : string
Return values
string —isBoardgame()
Checks whether this is a boardgame
public
isBoardgame() : bool
Return values
bool —isBook()
Checks whether this is a book
public
isBook() : bool
Return values
bool —isCalendar()
Checks whether this is a calendar
public
isCalendar() : bool
Return values
bool —isEbook()
Checks whether this is an eBook
public
isEbook() : bool
Return values
bool —isHardcover()
Checks whether this is a hardcover book
public
isHardcover() : bool
Return values
bool —isItem()
Checks whether this is an item
public
isItem() : bool
Return values
bool —isMap()
Checks whether this is a map
public
isMap() : bool
Return values
bool —isMedia()
Checks whether this is a medium
public
isMedia() : bool
Return values
bool —isMovie()
Checks whether this is a movie
public
isMovie() : bool
Return values
bool —isMusic()
Checks whether this is music
public
isMusic() : bool
Return values
bool —isNonbook()
Checks whether this is a generic item
public
isNonbook() : bool
Return values
bool —isNotes()
Checks whether these are notes
public
isNotes() : bool
Return values
bool —isSchoolbook()
Checks whether this is a schoolbook
public
isSchoolbook() : bool
Return values
bool —isSeries()
Checks whether product is part of (at least one) series
public
isSeries() : bool
Return values
bool —isSoftcover()
Checks whether this is a softcover book
public
isSoftcover() : bool
Return values
bool —isSoftware()
Checks whether this is software
public
isSoftware() : bool
Return values
bool —isSound()
Checks whether this is a sound storage medium
public
isSound() : bool
Return values
bool —isStationery()
Checks whether this is stationery
public
isStationery() : bool
Return values
bool —isToy()
Checks whether this is a toy
public
isToy() : bool
Return values
bool —isUnavailable()
Checks whether product is permanently unavailable
public
isUnavailable() : bool
Return values
bool —isVideogame()
Checks whether this is a videogame
public
isVideogame() : bool
Return values
bool —languages()
Exports language(s)
public
languages() : Value
Return values
Value —narrator()
Exports narrator(s)
public
narrator() : Role
Return values
Role —ola()
Exports OLA record
public
ola([int $quantity = 1 ][, string $type = 'anfrage' ]) : Ola
Parameters
- $quantity : int = 1
-
Number of products to be delivered
- $type : string = 'anfrage'
-
OLA type (either 'anfrage', 'bestellung' or 'storno')
Return values
Ola —olaCode()
Exports KNV 'Meldenummer' (if present)
public
olaCode() : string
Return values
string —olaMessage()
Exports KNV 'Meldetext' (if present)
public
olaMessage() : string
Return values
string —original()
Exports original author(s
public
original() : Role
Return values
Role —participant()
Exports participant(s)
public
participant() : Role
Return values
Role —people()
Exports (just) involved people
public
people() : Roles
Return values
Roles —photographer()
Exports photographer(s)
public
photographer() : Role
Return values
Role —producer()
Exports producer(s)
public
producer() : Role
Return values
Role —publisher()
Exports publisher(s)
public
publisher() : Value
Return values
Value —releaseYear()
Exports release year
public
releaseYear() : Value
Return values
Value —retailPrice()
Exports retail price (in €)
public
retailPrice() : Value
Examples:
- XX => XX,00
- XX.YY => XX,YY
Return values
Value —series()
Exports series & volume(s)
public
series() : Series
Return values
Series —subtitle()
Exports subtitle
public
subtitle() : Value
Return values
Value —title()
Exports title
public
title() : Value
Return values
Value —topics()
Exports topics
public
topics() : Value
Return values
Value —translator()
Exports translator(s)
public
translator() : Role
Return values
Role —type()
Detects product type
public
type() : string
Return values
string —vat()
Exports type of value added tax (VAT)
public
vat() : Value
Examples:
- '0' = none
- '1' = half
- '2' = full
Return values
Value —weight()
Exports weight (in g)
public
weight() : Value
Return values
Value —width()
Exports width (in cm)
public
width() : Value
Return values
Value —buildActor()
Builds actor(s)
protected
buildActor() : array<string|int, mixed>
Return values
array<string|int, mixed> —buildAuthor()
Builds author(s)
protected
buildAuthor() : array<string|int, mixed>
Return values
array<string|int, mixed> —buildComposer()
Builds composer(s)
protected
buildComposer() : array<string|int, mixed>
Return values
array<string|int, mixed> —buildDirector()
Builds director(s)
protected
buildDirector() : array<string|int, mixed>
Return values
array<string|int, mixed> —buildDrawer()
Builds drawer(s)
protected
buildDrawer() : array<string|int, mixed>
Return values
array<string|int, mixed> —buildEditor()
Builds editor(s)
protected
buildEditor() : array<string|int, mixed>
Return values
array<string|int, mixed> —buildIllustrator()
Builds illustrator(s)
protected
buildIllustrator() : array<string|int, mixed>
Return values
array<string|int, mixed> —buildNarrator()
Builds narrator(s)
protected
buildNarrator() : array<string|int, mixed>
Return values
array<string|int, mixed> —buildOriginal()
Builds original author(s)
protected
buildOriginal() : array<string|int, mixed>
Return values
array<string|int, mixed> —buildParticipant()
Builds participant(s)
protected
buildParticipant() : array<string|int, mixed>
Return values
array<string|int, mixed> —buildPhotographer()
Builds photographer(s)
protected
buildPhotographer() : array<string|int, mixed>
Return values
array<string|int, mixed> —buildProducer()
Builds producer(s)
protected
buildProducer() : array<string|int, mixed>
Return values
array<string|int, mixed> —buildTranslator()
Builds translator(s)
protected
buildTranslator() : array<string|int, mixed>
Return values
array<string|int, mixed> —convertMM()
Converts millimeters to centimeters
protected
convertMM(string $string) : string
Parameters
- $string : string
-
Millimeter information
Return values
string —getTags()
Extracts tags from raw data
protected
getTags() : array<string|int, mixed>
Return values
array<string|int, mixed> —organizePeople()
Parses & organizes involved people by first & last name
protected
organizePeople(string $string[, string $groupDelimiter = ';' ][, string $nameDelimiter = ',' ]) : array<string|int, mixed>
Example: 'Doe, John; Doe, Jane'
.. becomes ..
[ [ 'firstName' => 'John', 'lastName' => 'Doe', ], [ 'firstName' => 'Jane', 'lastName' => 'Doe', ], ]
Parameters
- $string : string
-
Involved people
- $groupDelimiter : string = ';'
-
Character between people
- $nameDelimiter : string = ','
-
Character between first & last name
Return values
array<string|int, mixed> —setUpPeople()
Extracts involved people from raw data
protected
setUpPeople() : array<string|int, mixed>
This includes the following roles by default:
-
author
-
original
-
illustrator
-
drawer
-
photographer
-
translator
-
narrator
-
composer
-
director
-
producer
-
actor
-
participant