org.exoplatform.faq.service
Class Question

java.lang.Object
  extended by org.exoplatform.faq.service.Question

public class Question
extends java.lang.Object

Data of question node is stored in question object which is used in processings: add new question, edit question and reponse question.

Author:
: Hung Nguyen Quang

Constructor Summary
Question()
          Class constructor specifying id of object is created.
 
Method Summary
 Answer[] getAnswers()
          Gets the answers.
 java.util.List<FileAttachment> getAttachMent()
          Get list files are attached to this quetsion.
 java.lang.String getAuthor()
          Get question's author who write question and wait an answer.
 java.lang.String getCategoryId()
          Get id of category which contain this question.
 Comment[] getComments()
          Gets the comments.
 java.util.Date getCreatedDate()
          Return date time when question is created or updated.
 java.lang.String getDetail()
          Get content of Question which is wanted answer.
 java.lang.String getEmail()
          Get email address of question's author.
 java.lang.String[] getEmailsWatch()
          Gets the emails watch.
 java.lang.String getId()
          Get id of Question object.
 java.lang.String getLanguage()
          Get question's language, this is default language of system when created question.
 java.lang.String getLanguagesNotYetAnswered()
          Get list languages of question which are not yet answered.
 java.lang.String getLink()
          Get link to question, this link is used to send mail notify, when user click in to this link, will be jump to FAQ and view this question.
 double getMarkVote()
          Gets the mark vote.
 QuestionLanguage[] getMultiLanguages()
           
 java.lang.String[] getNameAttachs()
          Gets the name attachs.
 java.lang.String getPath()
           
 java.lang.String getQuestion()
          Gets the question.
 java.lang.String[] getRelations()
          Get list questions in system which are like, related or support for this question.
 java.lang.String getTopicIdDiscuss()
          Gets the path topic discuss.
 java.lang.String[] getUsersVote()
          Gets the users vote.
 java.lang.String[] getUsersWatch()
          Gets the users watch.
 boolean isActivated()
          Return status of this question, return true if this question is activated and false if opposite.
 boolean isApproved()
          Return status of thi question, return true if this question is approved and false if opposite.
 void setActivated(boolean isActivated)
          Registers for this Question object is activated or not.
 void setAnswers(Answer[] answers)
          Sets the answers.
 void setApproved(boolean isApproved)
          Registers for this question is approved or not.
 void setAttachMent(java.util.List<FileAttachment> listFile)
          Registers list files will be attach to this question to description for this question.
 void setAuthor(java.lang.String author)
          Set name for property author of this question, author is person who write question and wait an answer.
 void setCategoryId(java.lang.String catId)
          Registers id for property categoryId of Question object, each question is contained in a category and this property is used to point this cateogry.
 void setComments(Comment[] comments)
          Sets the comments.
 void setCreatedDate(java.util.Date createdDate)
          Registers date time for Question object.
 void setDetail(java.lang.String name)
          Set content for Question object.
 void setEmail(java.lang.String email)
          Registers email address of question's author for this Question object.
 void setEmailsWatch(java.lang.String[] emailsWatch)
          Sets the emails watch.
 void setId(java.lang.String id)
          Set an id for Question object.
 void setLanguage(java.lang.String language)
          Set language for question, a language may be have multi languages but all of languages is used must be supported in portal.
 Question setLanguagesNotYetAnswered(java.lang.String languagesNotYetAnswered)
          Registers language is not yet answered.
 void setLink(java.lang.String link)
          Register link to question, this link is used to send mail notify, when user click in to this link, will be jump to FAQ and view this question.
 void setMarkVote(double markVote)
          Sets the mark vote.
 void setMultiLanguages(QuestionLanguage[] multiLanguages)
           
 void setNameAttachs(java.lang.String[] nameAttachs)
          Sets the name attachs.
 void setPath(java.lang.String path)
           
 void setQuestion(java.lang.String title)
          Sets the question.
 void setRelations(java.lang.String[] relations)
          Registers list questions is related or supported for this question.
 void setTopicIdDiscuss(java.lang.String topicIdDiscuss)
          Sets the path topic discuss.
 void setUsersVote(java.lang.String[] usersVote)
          Sets the users vote.
 void setUsersWatch(java.lang.String[] usersWatch)
          Sets the users watch.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Question

public Question()
Class constructor specifying id of object is created.

Method Detail

getId

public java.lang.String getId()
Get id of Question object.

Returns:
question's id

setId

public void setId(java.lang.String id)
Set an id for Question object.

Parameters:
id - the id of question object

getDetail

public java.lang.String getDetail()
Get content of Question which is wanted answer.

Returns:
the content of question

setDetail

public void setDetail(java.lang.String name)
Set content for Question object.

Parameters:
name - the content of question which is wanted answer

setLanguage

public void setLanguage(java.lang.String language)
Set language for question, a language may be have multi languages but all of languages is used must be supported in portal. And the language which is useing in portal will be auto setted for this quetsion.

Parameters:
language - the language is default language is used in system

getLanguage

public java.lang.String getLanguage()
Get question's language, this is default language of system when created question.

Returns:
language the language is default of system and question

setAuthor

public void setAuthor(java.lang.String author)
Set name for property author of this question, author is person who write question and wait an answer.

Parameters:
author - ther author of question

getAuthor

public java.lang.String getAuthor()
Get question's author who write question and wait an answer.

Returns:
author the name of question's author

getRelations

public java.lang.String[] getRelations()
Get list questions in system which are like, related or support for this question.

Returns:
relations return list question's content is like this question

setRelations

public void setRelations(java.lang.String[] relations)
Registers list questions is related or supported for this question.

Parameters:
relations - list questions have related with this question

setEmail

public void setEmail(java.lang.String email)
Registers email address of question's author for this Question object.

Parameters:
email - the email

getEmail

public java.lang.String getEmail()
Get email address of question's author.

Returns:
email the email address of person who write question

setCreatedDate

public void setCreatedDate(java.util.Date createdDate)
Registers date time for Question object.

Parameters:
createdDate - the date time when question is created

getCreatedDate

public java.util.Date getCreatedDate()
Return date time when question is created or updated.

Returns:
the date time of question

setActivated

public void setActivated(boolean isActivated)
Registers for this Question object is activated or not. This setting with set approve for question will allow question is viewed or not

Parameters:
isActivated - is true if this question is activated and is false if this questiosn is not activated

isActivated

public boolean isActivated()
Return status of this question, return true if this question is activated and false if opposite.

Returns:
status of this question object, is activated or not

setApproved

public void setApproved(boolean isApproved)
Registers for this question is approved or not. This setting with set activate for question will allow this question is viewed or not

Parameters:
isApproved - is true if this question is approved and is false if this question is not approved

isApproved

public boolean isApproved()
Return status of thi question, return true if this question is approved and false if opposite.

Returns:
status of question is approved or not

setCategoryId

public void setCategoryId(java.lang.String catId)
Registers id for property categoryId of Question object, each question is contained in a category and this property is used to point this cateogry.

Parameters:
catId - id of category which contain this question

getCategoryId

public java.lang.String getCategoryId()
Get id of category which contain this question.

Returns:
an id of category which thi question

setAttachMent

public void setAttachMent(java.util.List<FileAttachment> listFile)
Registers list files will be attach to this question to description for this question. Each file have size is less than 10MB and larger 0B

Parameters:
listFile - list files are attached to question.

getAttachMent

public java.util.List<FileAttachment> getAttachMent()
Get list files are attached to this quetsion.

Returns:
list files are attached to this quetsion
See Also:
FileAttachment

getLanguagesNotYetAnswered

public java.lang.String getLanguagesNotYetAnswered()
Get list languages of question which are not yet answered.

Returns:
list languages

setLanguagesNotYetAnswered

public Question setLanguagesNotYetAnswered(java.lang.String languagesNotYetAnswered)
Registers language is not yet answered.

Parameters:
languagesNotYetAnswered - the languages not yet answered
Returns:
the question

getNameAttachs

public java.lang.String[] getNameAttachs()
Gets the name attachs.

Returns:
the name attachs

setNameAttachs

public void setNameAttachs(java.lang.String[] nameAttachs)
Sets the name attachs.

Parameters:
nameAttachs - the new name attachs

getLink

public java.lang.String getLink()
Get link to question, this link is used to send mail notify, when user click in to this link, will be jump to FAQ and view this question.

Returns:
link to question

setLink

public void setLink(java.lang.String link)
Register link to question, this link is used to send mail notify, when user click in to this link, will be jump to FAQ and view this question.

Parameters:
link - the link

getUsersVote

public java.lang.String[] getUsersVote()
Gets the users vote.

Returns:
the users vote

setUsersVote

public void setUsersVote(java.lang.String[] usersVote)
Sets the users vote.

Parameters:
usersVote - the new users vote

getMarkVote

public double getMarkVote()
Gets the mark vote.

Returns:
the mark vote

setMarkVote

public void setMarkVote(double markVote)
Sets the mark vote.

Parameters:
markVote - the new mark vote

getUsersWatch

public java.lang.String[] getUsersWatch()
Gets the users watch.

Returns:
the users watch

setUsersWatch

public void setUsersWatch(java.lang.String[] usersWatch)
Sets the users watch.

Parameters:
usersWatch - the new users watch

getEmailsWatch

public java.lang.String[] getEmailsWatch()
Gets the emails watch.

Returns:
the emails watch

setEmailsWatch

public void setEmailsWatch(java.lang.String[] emailsWatch)
Sets the emails watch.

Parameters:
emailsWatch - the new emails watch

getQuestion

public java.lang.String getQuestion()
Gets the question.

Returns:
the question

setQuestion

public void setQuestion(java.lang.String title)
Sets the question.

Parameters:
title - the new question

getTopicIdDiscuss

public java.lang.String getTopicIdDiscuss()
Gets the path topic discuss.

Returns:
the path topic discuss

setTopicIdDiscuss

public void setTopicIdDiscuss(java.lang.String topicIdDiscuss)
Sets the path topic discuss.

Parameters:
pathTopicDiscus - the new path topic discuss

getAnswers

public Answer[] getAnswers()
Gets the answers.

Returns:
the answers

setAnswers

public void setAnswers(Answer[] answers)
Sets the answers.

Parameters:
answers - the new answers

getComments

public Comment[] getComments()
Gets the comments.

Returns:
the comments

setComments

public void setComments(Comment[] comments)
Sets the comments.

Parameters:
comments - the new comments

setPath

public void setPath(java.lang.String path)

getPath

public java.lang.String getPath()

setMultiLanguages

public void setMultiLanguages(QuestionLanguage[] multiLanguages)

getMultiLanguages

public QuestionLanguage[] getMultiLanguages()


Copyright © 2011 eXo Platform SAS. All Rights Reserved.