// Path: organization-structure-sql/src/main/java/org/javers/organization/structure/domain/Employee.java
// @Entity
// @Table
// public class Employee implements Serializable {
// 
//     @Id
//     @Column(name = "domain_name")
//     private String domainName;
// 
//     @OneToOne
//     @JsonIgnore
//     private Person person;
// 
//     public Person getPerson() {
//         return person;
//     }
// 
//     public void setPerson(Person person) {
//         this.person = person;
//     }
// 
//     public String getDomainName() {
//         return domainName;
//     }
// 
//     public void setDomainName(String domainName) {
//         this.domainName = domainName;
//     }
// }
// 
// Path: organization-structure-sql/src/main/java/org/javers/organization/structure/domain/Hierarchy.java
// @Entity
// @Table
// public class Hierarchy implements Serializable{
// 
//     @Id
//     private String name;
// 
//     @OneToMany(mappedBy = "hierarchy", fetch = FetchType.EAGER)
//     private List<HierarchyEmployees> hierarchyEmployees;
// 
// 
//     public Hierarchy() {
//     }
// 
//     public String getName() {
//         return name;
//     }
// 
//     public void setName(String name) {
//         this.name = name;
//     }
// 
//     public List<HierarchyEmployees> getHierarchyEmployees() {
//         return hierarchyEmployees;
//     }
// 
//     public void setHierarchyEmployees(List<HierarchyEmployees> hierarchyEmployees) {
//         this.hierarchyEmployees = hierarchyEmployees;
//     }
// }
// 
// Path: organization-structure-mongo/src/main/java/org/javers/organization/structure/domain/HierarchyRepository.java
// public interface HierarchyRepository extends CrudRepository<Hierarchy, String> {
// }
// 
// Path: organization-structure-mongo/src/main/java/org/javers/organization/structure/domain/Person.java
// @Document
// public class Person {
// 
//     @Id
//     private int id;
//     private String firstName;
//     private String lastName;
//     private Sex sex;
//     private Integer salary;
//     private Position position;
//     @Version
//     private Long version;
// 
//     public Person() {
//     }
// 
//     public Person(int id, String firstName, String lastName, Sex sex) {
//         this.id = id;
//         this.firstName = firstName;
//         this.lastName = lastName;
//         this.sex = sex;
//     }
// 
//     public Person(int id, String firstName, String lastName, Sex sex, Integer salary, Position position) {
//         this.id = id;
//         this.firstName = firstName;
//         this.lastName = lastName;
//         this.sex = sex;
//         this.salary = salary;
//         this.position = position;
//     }
// 
//     public Person assignPosition(Position position, int salary) {
//         this.position = position;
//         this.salary = salary;
//         return this;
//     }
// 
//     public int getId() {
//         return id;
//     }
// 
//     public String getFirstName() {
//         return firstName;
//     }
// 
//     public String getLastName() {
//         return lastName;
//     }
// 
//     public Sex getSex() {
//         return sex;
//     }
// 
//     public Integer getSalary() {
//         return salary;
//     }
// 
//     public Position getPosition() {
//         return position;
//     }
// 
//     public Employee toEmployee() {
//         return new Employee(firstName+"."+lastName, id);
//     }
// 
//     public void setSalary(Integer salary) {
//         this.salary = salary;
//     }
// }
// 
// Path: organization-structure-sql/src/main/java/org/javers/organization/structure/domain/PersonRepository.java
// @JaversSpringDataAuditable
// public interface PersonRepository extends CrudRepository<Person, Integer> {
// 
// }
// 
// Path: organization-structure-mongo/src/main/java/org/javers/organization/structure/domain/Position.java
// public enum Position {
//     DEVELOPER,
//     SCRUM_MASTER,
//     TEAM_LEAD,
//     IT_MANAGER,
//     CTO
// }
// 
// Path: organization-structure-mongo/src/main/java/org/javers/organization/structure/domain/Sex.java
// public enum Sex {
//     FEMALE,
//     MALE
// }


import com.google.common.collect.Lists;
import org.javers.core.Javers;
import org.javers.organization.structure.domain.Employee;
import org.javers.organization.structure.domain.Hierarchy;
import org.javers.organization.structure.domain.HierarchyRepository;
import org.javers.organization.structure.domain.Person;
import org.javers.organization.structure.domain.PersonRepository;
import org.javers.organization.structure.domain.Position;
import org.javers.organization.structure.domain.Sex;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.data.mongodb.core.MongoTemplate;
import org.springframework.stereotype.Component;
import java.util.List;
package org.javers.organization.structure.infrastructure;



/**
 * @author bartosz walacik
 */
@Component
public class MongoDataInitializer {

    Person frodo;
    Person bilbo;
    Person sam;
    Person merry;
    Person lucy;
    Person eva;
    Person charlie;
    Person kaz;
    Person stef;
    Person bob;

    Person stanMarsh;
    Person kyleBroflovski;
    Person ericCartman;
    Person kennyMcCormick;

    List<Person> persons;

    Employee eFrodo;
    Employee eBilbo;
    Employee eSam;
// Path: organization-structure-sql/src/main/java/org/javers/organization/structure/domain/Employee.java
// @Entity
// @Table
// public class Employee implements Serializable {
// 
//     @Id
//     @Column(name = "domain_name")
//     private String domainName;
// 
//     @OneToOne
//     @JsonIgnore
//     private Person person;
// 
//     public Person getPerson() {
//         return person;
//     }
// 
//     public void setPerson(Person person) {
//         this.person = person;
//     }
// 
//     public String getDomainName() {
//         return domainName;
//     }
// 
//     public void setDomainName(String domainName) {
//         this.domainName = domainName;
//     }
// }
// 
// Path: organization-structure-sql/src/main/java/org/javers/organization/structure/domain/Hierarchy.java
// @Entity
// @Table
// public class Hierarchy implements Serializable{
// 
//     @Id
//     private String name;
// 
//     @OneToMany(mappedBy = "hierarchy", fetch = FetchType.EAGER)
//     private List<HierarchyEmployees> hierarchyEmployees;
// 
// 
//     public Hierarchy() {
//     }
// 
//     public String getName() {
//         return name;
//     }
// 
//     public void setName(String name) {
//         this.name = name;
//     }
// 
//     public List<HierarchyEmployees> getHierarchyEmployees() {
//         return hierarchyEmployees;
//     }
// 
//     public void setHierarchyEmployees(List<HierarchyEmployees> hierarchyEmployees) {
//         this.hierarchyEmployees = hierarchyEmployees;
//     }
// }
// 
// Path: organization-structure-mongo/src/main/java/org/javers/organization/structure/domain/HierarchyRepository.java
// public interface HierarchyRepository extends CrudRepository<Hierarchy, String> {
// }
// 
// Path: organization-structure-mongo/src/main/java/org/javers/organization/structure/domain/Person.java
// @Document
// public class Person {
// 
//     @Id
//     private int id;
//     private String firstName;
//     private String lastName;
//     private Sex sex;
//     private Integer salary;
//     private Position position;
//     @Version
//     private Long version;
// 
//     public Person() {
//     }
// 
//     public Person(int id, String firstName, String lastName, Sex sex) {
//         this.id = id;
//         this.firstName = firstName;
//         this.lastName = lastName;
//         this.sex = sex;
//     }
// 
//     public Person(int id, String firstName, String lastName, Sex sex, Integer salary, Position position) {
//         this.id = id;
//         this.firstName = firstName;
//         this.lastName = lastName;
//         this.sex = sex;
//         this.salary = salary;
//         this.position = position;
//     }
// 
//     public Person assignPosition(Position position, int salary) {
//         this.position = position;
//         this.salary = salary;
//         return this;
//     }
// 
//     public int getId() {
//         return id;
//     }
// 
//     public String getFirstName() {
//         return firstName;
//     }
// 
//     public String getLastName() {
//         return lastName;
//     }
// 
//     public Sex getSex() {
//         return sex;
//     }
// 
//     public Integer getSalary() {
//         return salary;
//     }
// 
//     public Position getPosition() {
//         return position;
//     }
// 
//     public Employee toEmployee() {
//         return new Employee(firstName+"."+lastName, id);
//     }
// 
//     public void setSalary(Integer salary) {
//         this.salary = salary;
//     }
// }
// 
// Path: organization-structure-sql/src/main/java/org/javers/organization/structure/domain/PersonRepository.java
// @JaversSpringDataAuditable
// public interface PersonRepository extends CrudRepository<Person, Integer> {
// 
// }
// 
// Path: organization-structure-mongo/src/main/java/org/javers/organization/structure/domain/Position.java
// public enum Position {
//     DEVELOPER,
//     SCRUM_MASTER,
//     TEAM_LEAD,
//     IT_MANAGER,
//     CTO
// }
// 
// Path: organization-structure-mongo/src/main/java/org/javers/organization/structure/domain/Sex.java
// public enum Sex {
//     FEMALE,
//     MALE
// }


// Path: organization-structure-mongo/src/main/java/org/javers/organization/structure/infrastructure/MongoDataInitializer.java
import com.google.common.collect.Lists;
import org.javers.core.Javers;
import org.javers.organization.structure.domain.Employee;
import org.javers.organization.structure.domain.Hierarchy;
import org.javers.organization.structure.domain.HierarchyRepository;
import org.javers.organization.structure.domain.Person;
import org.javers.organization.structure.domain.PersonRepository;
import org.javers.organization.structure.domain.Position;
import org.javers.organization.structure.domain.Sex;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.data.mongodb.core.MongoTemplate;
import org.springframework.stereotype.Component;
import java.util.List;

package org.javers.organization.structure.infrastructure;



/**
 * @author bartosz walacik
 */
@Component
public class MongoDataInitializer {

    Person frodo;
    Person bilbo;
    Person sam;
    Person merry;
    Person lucy;
    Person eva;
    Person charlie;
    Person kaz;
    Person stef;
    Person bob;

    Person stanMarsh;
    Person kyleBroflovski;
    Person ericCartman;
    Person kennyMcCormick;

    List<Person> persons;

    Employee eFrodo;
    Employee eBilbo;
    Employee eSam;
    Employee eMerry;