src/org/sonews/storage/Article.java
changeset 117 79ce65d63cce
parent 101 d54786065fa3
     1.1 --- a/src/org/sonews/storage/Article.java	Sun Nov 06 00:08:05 2011 +0100
     1.2 +++ b/src/org/sonews/storage/Article.java	Mon Nov 07 17:35:43 2011 +0100
     1.3 @@ -31,6 +31,7 @@
     1.4  import javax.mail.Message;
     1.5  import javax.mail.MessagingException;
     1.6  import javax.mail.internet.InternetHeaders;
     1.7 +import org.sonews.acl.User;
     1.8  import org.sonews.config.Config;
     1.9  import org.sonews.util.Log;
    1.10  
    1.11 @@ -42,7 +43,7 @@
    1.12   */
    1.13  public class Article extends ArticleHead {
    1.14  	
    1.15 -	private String authenticatedUser;
    1.16 +	private User sender;
    1.17  
    1.18  	/**
    1.19  	 * Loads the Article identified by the given ID from the JDBCDatabase.
    1.20 @@ -224,17 +225,17 @@
    1.21  	}
    1.22  
    1.23  	/**
    1.24 -	 * @return username of currently logged user – or null, if user is not authenticated.
    1.25 +	 * @return sender – currently logged user – or null, if user is not authenticated.
    1.26  	 */
    1.27 -	public String getAuthenticatedUser() {
    1.28 -		return authenticatedUser;
    1.29 +	public User getUser() {
    1.30 +		return sender;
    1.31  	}
    1.32  	
    1.33  	/**
    1.34  	 * This method is to be called from POST Command implementation.
    1.35 -	 * @param authenticatedUser current username – or null, if user is not authenticated.
    1.36 +	 * @param sender current username – or null, if user is not authenticated.
    1.37  	 */
    1.38 -	public void setAuthenticatedUser(String authenticatedUser) {
    1.39 -		this.authenticatedUser = authenticatedUser;
    1.40 +	public void setUser(User sender) {
    1.41 +		this.sender = sender;
    1.42  	}
    1.43  }