예제 #1
0
    "http://www.getty.edu/art/collection/objects/882/rembrandt-harmensz-van-rijn-the-abduction-of-europa-dutch-1632/",
    label="The Abduction of Europa",
    art=1)

# Title
obj.identified_by = PrimaryName(label="Title", value="The Abduction of Europa")
obj.identified_by = Name(label="ALternate Title",
                         value="El rapto de Europa (Published Title)")

prod = Production()
obj.produced_by = prod

# Collection
col = CollectionSet("http://www.getty.edu/art/collection/",
                    label="The J. Paul Getty Museum Collection")
obj.aggregated_by = col

# Artist info
artist = Actor(
    "http://www.getty.edu/art/collection/artists/469/rembrandt-harmensz-van-rijn-dutch-1606-1669/",
    label="Artist")
artist.identified_by = PrimaryName(value="Rembrandt Harmensz. van Rijn")
artist.classified_as = instances["dutch nationality"]
birth = BeginningOfExistence()
btime = TimeSpan(label="1606")
btime.begin_of_the_begin = "1606-01-01T00:00:00Z"
btime.end_of_the_end = "1607-01-01T00:00:00Z"
birth.timespan = btime
death = EndOfExistence()
dtime = TimeSpan(label="1669")
dtime.begin_of_the_begin = "1669-01-01T00:00:00Z"
예제 #2
0
# obj.identified_by = loc_num

# print (factory.toString(obj, compact=False))




# Example of Context for Non-URI Identifiers

from cromulent.vocab import Painting, AccessionNumber, add_art_setter
add_art_setter - 
acc_num = AccessionNumber("https://linked.art/example/identifier/9", value="P1998-27")
aggr = Aggregation("https://linked.art/example/set/15", label="Paintings Collection")
o = Painting("https://linked.art/example/object/47", label="Example Painting", art=1)
o.identified_by = acc_num
o.aggregated_by = aggr 
print (factory.toString(o, compact=False))





# Example of Titles

# from cromulent.vocab import Painting, PrimaryName, Name, add_art_setter
# add_art_setter()
# ptitle = "Self Portrait"
# atitle = "Portrait of the Artist"
# prim_name = PrimaryName("https://linked.art/example/name/16", value=ptitle)
# alt_name = Name("https://linked.art/example/name/18", value=atitle)
# obj = Painting("https://linked.art/example/object/48", label=ptitle, art=1)