# Path: premis_event_service/models.py
# AGENT_TYPE_CHOICES = [
#     ('Personal', 'Personal'),
#     ('Organization', 'Organization'),
#     ('Event', 'Event'),
#     ('Software', 'Software'),
# ]
# class Agent(models.Model):
#     class Meta:
# class LinkObject(models.Model):
# class EventManager(models.Manager):
# class Event(models.Model):
#     class Meta:
# class EventLinkObject(models.Model):
#     class Meta:
#     def __str__(self):
#     def get_absolute_url(self):
#     def __str__(self):
#     def search(self, **kwargs):
#     def searchunfilt(self, max_ordinal=None):
#     def __str__(self):
#     def link_objects_string(self):
#     def is_good(self):
# 
# Path: premis_event_service/settings.py
# EVENT_ID_TYPE_XML = getattr(
#     settings, 'EVENT_ID_TYPE_XML',
#     "http://purl.org/net/untl/vocabularies/identifier-qualifiers/#UUID"
# )
# LINK_AGENT_ID_TYPE_XML = getattr(
#     settings, 'LINK_AGENT_ID_TYPE_XML',
#     "http://purl.org/net/untl/vocabularies/identifier-qualifiers/#URL"
# )
# LINK_AGENT_ID_ROLE_XML = getattr(
#     settings, 'LINK_AGENT_ID_ROLE_XML',
#     "http://id.loc.gov/vocabulary/preservation/eventRelatedAgentRole/exe"
# )
# BAGATOM_BAG_NAMESPACE = getattr(
#     settings, 'BAGATOM_BAG_NAMESPACE', "TODO"
# )
# BAGATOM_QXML_NAMESPACE = getattr(
#     settings, 'BAGATOM_QXML_NAMESPACE', "TODO"
# )
# BAGATOM_NODE_NAMESPACE = getattr(
#     settings, 'BAGATOM_NODE_NAMESPACE', "TODO"
# )
# EVENT_OUTCOME_CHOICES = getattr(
#     settings, 'EVENT_OUTCOME_CHOICES',
#     (
#         ('', 'None'),
#         ('http://purl.org/net/untl/vocabularies/eventOutcomes/#success', 'Success'),
#         ('http://purl.org/net/untl/vocabularies/eventOutcomes/#failure', 'Failure'),
#     )
# )
# EVENT_TYPE_CHOICES = getattr(
#     settings, 'EVENT_TYPE_CHOICES',
#     (
#         ('', 'None'),
#         ('http://purl.org/net/untl/vocabularies/preservationEvents/#fixityCheck', 'Fixity Check'),
#         ('http://purl.org/net/untl/vocabularies/preservationEvents/#replication', 'Replication'),
#         ('http://purl.org/net/untl/vocabularies/preservationEvents/#ingestion', 'Ingestion'),
#         ('http://purl.org/net/untl/vocabularies/preservationEvents/#migration', 'Migration'),
#     )
# )
# ARK_NAAN = getattr(settings, 'ARK_NAAN', 67531)


import uuid
import factory
import factory.fuzzy
from datetime import datetime
from premis_event_service import models, settings

EVENT_OUTCOMES = [value for value, _ in settings.EVENT_OUTCOME_CHOICES if value]

AGENTS = [
    'http://example.com/agent/codareplicationverification',
    'http://example.com/agent/codavalidation',
]


class AgentFactory(factory.django.DjangoModelFactory):

    class Meta:
        model = models.Agent

    agent_identifier = factory.fuzzy.FuzzyText()
    agent_name = factory.fuzzy.FuzzyText()
    agent_type = factory.fuzzy.FuzzyChoice(v for k, v in models.AGENT_TYPE_CHOICES)
    agent_note = factory.fuzzy.FuzzyText()


class LinkObjectFactory(factory.django.DjangoModelFactory):

    class Meta:
        model = models.LinkObject

    object_identifier = factory.Sequence(lambda n: 'ark:/00001/coda{0}'.format(n))
    object_type = 'http://purl.org/net/untl/vocabularies/identifier-qualifiers/#ARK'
    object_role = None



# Path: premis_event_service/models.py
# AGENT_TYPE_CHOICES = [
#     ('Personal', 'Personal'),
#     ('Organization', 'Organization'),
#     ('Event', 'Event'),
#     ('Software', 'Software'),
# ]
# class Agent(models.Model):
#     class Meta:
# class LinkObject(models.Model):
# class EventManager(models.Manager):
# class Event(models.Model):
#     class Meta:
# class EventLinkObject(models.Model):
#     class Meta:
#     def __str__(self):
#     def get_absolute_url(self):
#     def __str__(self):
#     def search(self, **kwargs):
#     def searchunfilt(self, max_ordinal=None):
#     def __str__(self):
#     def link_objects_string(self):
#     def is_good(self):
# 
# Path: premis_event_service/settings.py
# EVENT_ID_TYPE_XML = getattr(
#     settings, 'EVENT_ID_TYPE_XML',
#     "http://purl.org/net/untl/vocabularies/identifier-qualifiers/#UUID"
# )
# LINK_AGENT_ID_TYPE_XML = getattr(
#     settings, 'LINK_AGENT_ID_TYPE_XML',
#     "http://purl.org/net/untl/vocabularies/identifier-qualifiers/#URL"
# )
# LINK_AGENT_ID_ROLE_XML = getattr(
#     settings, 'LINK_AGENT_ID_ROLE_XML',
#     "http://id.loc.gov/vocabulary/preservation/eventRelatedAgentRole/exe"
# )
# BAGATOM_BAG_NAMESPACE = getattr(
#     settings, 'BAGATOM_BAG_NAMESPACE', "TODO"
# )
# BAGATOM_QXML_NAMESPACE = getattr(
#     settings, 'BAGATOM_QXML_NAMESPACE', "TODO"
# )
# BAGATOM_NODE_NAMESPACE = getattr(
#     settings, 'BAGATOM_NODE_NAMESPACE', "TODO"
# )
# EVENT_OUTCOME_CHOICES = getattr(
#     settings, 'EVENT_OUTCOME_CHOICES',
#     (
#         ('', 'None'),
#         ('http://purl.org/net/untl/vocabularies/eventOutcomes/#success', 'Success'),
#         ('http://purl.org/net/untl/vocabularies/eventOutcomes/#failure', 'Failure'),
#     )
# )
# EVENT_TYPE_CHOICES = getattr(
#     settings, 'EVENT_TYPE_CHOICES',
#     (
#         ('', 'None'),
#         ('http://purl.org/net/untl/vocabularies/preservationEvents/#fixityCheck', 'Fixity Check'),
#         ('http://purl.org/net/untl/vocabularies/preservationEvents/#replication', 'Replication'),
#         ('http://purl.org/net/untl/vocabularies/preservationEvents/#ingestion', 'Ingestion'),
#         ('http://purl.org/net/untl/vocabularies/preservationEvents/#migration', 'Migration'),
#     )
# )
# ARK_NAAN = getattr(settings, 'ARK_NAAN', 67531)


# Path: tests/factories.py
import uuid
import factory
import factory.fuzzy
from datetime import datetime
from premis_event_service import models, settings


EVENT_OUTCOMES = [value for value, _ in settings.EVENT_OUTCOME_CHOICES if value]

AGENTS = [
    'http://example.com/agent/codareplicationverification',
    'http://example.com/agent/codavalidation',
]


class AgentFactory(factory.django.DjangoModelFactory):

    class Meta:
        model = models.Agent

    agent_identifier = factory.fuzzy.FuzzyText()
    agent_name = factory.fuzzy.FuzzyText()
    agent_type = factory.fuzzy.FuzzyChoice(v for k, v in models.AGENT_TYPE_CHOICES)
    agent_note = factory.fuzzy.FuzzyText()


class LinkObjectFactory(factory.django.DjangoModelFactory):

    class Meta:
        model = models.LinkObject

    object_identifier = factory.Sequence(lambda n: 'ark:/00001/coda{0}'.format(n))
    object_type = 'http://purl.org/net/untl/vocabularies/identifier-qualifiers/#ARK'
    object_role = None



class EventFactory(factory.django.DjangoModelFactory):