Project

General

Profile

« Previous | Next » 

Revision 4ac5c0e4

Added by Andreas Müller over 6 years ago

cleanup

View differences:

cdmlib-model/src/main/java/eu/etaxonomy/cdm/model/media/AudioFile.java
1 1
/**
2 2
* Copyright (C) 2007 EDIT
3
* European Distributed Institute of Taxonomy 
3
* European Distributed Institute of Taxonomy
4 4
* http://www.e-taxonomy.eu
5
* 
5
*
6 6
* The contents of this file are subject to the Mozilla Public License Version 1.1
7 7
* See LICENSE.TXT at the top of this package for the full license terms.
8 8
*/
......
11 11

  
12 12
import java.net.URI;
13 13

  
14
import org.apache.log4j.Logger;
15
import org.hibernate.envers.Audited;
16

  
17
import javax.persistence.*;
14
import javax.persistence.Entity;
18 15
import javax.xml.bind.annotation.XmlAccessType;
19 16
import javax.xml.bind.annotation.XmlAccessorType;
20 17
import javax.xml.bind.annotation.XmlElement;
21 18
import javax.xml.bind.annotation.XmlRootElement;
22 19
import javax.xml.bind.annotation.XmlType;
23 20

  
21
import org.apache.log4j.Logger;
22
import org.hibernate.envers.Audited;
23

  
24 24
/**
25 25
 * @author m.doering
26
 * @version 1.0
27 26
 * @created 08-Nov-2007 13:06:11
28 27
 */
29 28
@XmlAccessorType(XmlAccessType.FIELD)
......
36 35
public class AudioFile extends MediaRepresentationPart {
37 36
	private static final long serialVersionUID = 2327736023969971196L;
38 37
	private static final Logger logger = Logger.getLogger(AudioFile.class);
39
	
38

  
40 39
	//length of recording in seconds
41 40
	@XmlElement(name = "Duration")
42 41
	private int duration;
43 42

  
43

  
44
// *************** FACTORY METHOD *********************************/
45

  
44 46
	public static AudioFile NewInstance(URI uri, Integer size){
45 47
		logger.debug("NewInstance");
46 48
		return new AudioFile(uri, size);
47 49
	}
48

  
49
	/**
50
	 * Factory method
51
	 * @return
52
	 */
53 50
	public static AudioFile NewInstance(){
54 51
		return new AudioFile();
55 52
	}
56
	
57
	/**
58
	 * Constructor
59
	 */
53

  
54
// ********************** CONSTRUCTOR ***************************/
60 55
	protected AudioFile() {
61 56
		super();
62 57
	}
63
	
64
	/**
65
	 * Constructor
66
	 */
58

  
67 59
	protected AudioFile(URI uri, Integer size) {
68 60
		super(uri, size);
69 61
	}
70
	
62

  
63
// ******************** GETTER / SETTER *************************/
71 64
	public int getDuration(){
72 65
		return this.duration;
73 66
	}
74

  
75
	/**
76
	 * 
77
	 * @param duration    duration
78
	 */
79 67
	public void setDuration(int duration){
80 68
		this.duration = duration;
81 69
	}

Also available in: Unified diff