public class PolyvQuestionVO
extends java.lang.Object
setShowTime(int)
的时间自动弹出,弹出动作是回调IPolyvOnQuestionListener.onPopUp(PolyvQuestionVO)
方法。PolyvVideoView.answerQuestion2(List)
回答问答,或者PolyvVideoView.skipQuestion()
跳过问答,
回答问答的回调是IPolyvOnQuestionListener.onAnswerResult(boolean, PolyvQuestionVO, String, int)
方法,掉过问答的回调是IPolyvOnQuestionListener.onSkipCallback(PolyvQuestionVO)
方法。PolyvVideoView.doneQuestion(int)
表示当前问答已经完成。限定符和类型 | 字段和说明 |
---|---|
static int |
TYPE_AUDITION
听力类型
|
static int |
TYPE_QUESTION
问答类型
|
构造器和说明 |
---|
PolyvQuestionVO(java.lang.String examId,
java.lang.String question,
java.util.List<PolyvQuestionChoicesVO> choicesList,
java.lang.String rightAnswerTip,
boolean skip,
int type,
int wrongTime,
java.lang.String wrongAnswerTip,
java.lang.String illustration)
自定义问答使用的构造方法
|
PolyvQuestionVO(java.lang.String examId,
java.lang.String userId,
java.lang.String vid,
java.lang.String showTime,
int hours,
int minutes,
int seconds,
java.lang.String question,
java.util.List<QuestionVO.ChoicesVO> choicesList,
java.lang.String rightAnswerTip,
boolean skip,
int type,
java.lang.String mp3url,
int wrongTime,
int wrongShow,
int status,
long createdTime,
boolean isFromDownload) |
PolyvQuestionVO(java.lang.String examId,
java.lang.String userId,
java.lang.String vid,
java.lang.String showTime,
int hours,
int minutes,
int seconds,
java.lang.String question,
java.util.List<QuestionVO.ChoicesVO> choicesList,
java.lang.String rightAnswerTip,
boolean skip,
int type,
java.lang.String mp3url,
int wrongTime,
int wrongShow,
int status,
long createdTime,
boolean isFromDownload,
java.lang.String wrongAnswerTip,
java.lang.String illustration) |
限定符和类型 | 方法和说明 |
---|---|
void |
clearChoicesSelected()
清理选项选中
|
static QuestionVO |
copyToQuestion(PolyvQuestionVO questionVO) |
static java.util.List<PolyvQuestionVO> |
formatJSONObject(org.json.JSONArray jsonArray,
boolean isFromDownload)
格式化
|
static java.util.List<PolyvQuestionVO> |
formatQuestion(java.lang.String body,
boolean isFromDownload)
已过时。
|
java.lang.String |
formatRightChoices()
获取格式化后的正确答案,用于发送答题统计
|
java.lang.String |
getAnswer()
获取回答正确提示语
|
java.util.List<QuestionVO.ChoicesVO> |
getChoicesList()
获取选项列表
|
java.util.List<PolyvQuestionChoicesVO> |
getChoicesList2()
获取选项列表
|
long |
getCreatedTime() |
java.lang.String |
getExamId()
获取问答题目ID
|
int |
getHours() |
java.lang.String |
getIllustration()
获取问答展示图片
|
int |
getMinutes() |
java.lang.String |
getMp3url() |
java.lang.String |
getQuestion()
获取问答题目
|
int |
getSeconds() |
java.lang.String |
getShowTime() |
int |
getShowTimeTotalMilliseconds()
获取题目出现时间点,格式化成毫秒返回
|
int |
getShowTimeTotalSeconds()
获取题目出现时间点,格式化成秒返回
|
int |
getStatus() |
int |
getType()
类型,本类定义的TYPE_ 开头的常量
|
java.lang.String |
getUserId() |
java.lang.String |
getVid() |
java.lang.String |
getWrongAnswer()
获取回答错误提示语
|
int |
getWrongShow() |
int |
getWrongTime()
获取回答错误后跳回的时间点
|
int |
getWrongTimeTotalMilliseconds()
获取回答错误后跳回的时间点
|
boolean |
illustrationIsEmpty()
问答展示图片是否为空
|
boolean |
isFromDownload() |
boolean |
isMultiSelected()
是否多选题
单个正确答案是单选,多个正确答案是多选
|
boolean |
isSkip()
能否跳过问答
|
void |
setShowTime(int totalSeconds)
设置题目出现时间点
取值范围: 负数,0~视频时长
如果是负数,会直接弹出题目。
|
void |
setUserId(java.lang.String userId) |
void |
setVid(java.lang.String vid) |
java.lang.String |
toString() |
public static final int TYPE_QUESTION
public static final int TYPE_AUDITION
public PolyvQuestionVO(java.lang.String examId, java.lang.String question, java.util.List<PolyvQuestionChoicesVO> choicesList, java.lang.String rightAnswerTip, boolean skip, int type, int wrongTime, java.lang.String wrongAnswerTip, java.lang.String illustration)
examId
- 问答题目IDquestion
- 问答题目choicesList
- 选项列表rightAnswerTip
- 回答正确提示语skip
- 能否跳过问答type
- 类型,本类定义的TYPE_ 开头的常量wrongTime
- 回答错误后跳回的时间点,单位秒wrongAnswerTip
- 回答错误提示语illustration
- 问答图片展示public PolyvQuestionVO(java.lang.String examId, java.lang.String userId, java.lang.String vid, java.lang.String showTime, int hours, int minutes, int seconds, java.lang.String question, java.util.List<QuestionVO.ChoicesVO> choicesList, java.lang.String rightAnswerTip, boolean skip, int type, java.lang.String mp3url, int wrongTime, int wrongShow, int status, long createdTime, boolean isFromDownload)
public PolyvQuestionVO(java.lang.String examId, java.lang.String userId, java.lang.String vid, java.lang.String showTime, int hours, int minutes, int seconds, java.lang.String question, java.util.List<QuestionVO.ChoicesVO> choicesList, java.lang.String rightAnswerTip, boolean skip, int type, java.lang.String mp3url, int wrongTime, int wrongShow, int status, long createdTime, boolean isFromDownload, java.lang.String wrongAnswerTip, java.lang.String illustration)
public java.lang.String getExamId()
public java.lang.String getUserId()
public void setUserId(java.lang.String userId)
public java.lang.String getVid()
public void setVid(java.lang.String vid)
public void setShowTime(int totalSeconds)
totalSeconds
- 单位秒public java.lang.String getShowTime()
public int getShowTimeTotalSeconds()
public int getShowTimeTotalMilliseconds()
public int getHours()
public int getMinutes()
public int getSeconds()
public java.lang.String getQuestion()
public java.util.List<QuestionVO.ChoicesVO> getChoicesList()
public java.util.List<PolyvQuestionChoicesVO> getChoicesList2()
public boolean isMultiSelected()
true
:是,false
:否public void clearChoicesSelected()
public java.lang.String formatRightChoices()
public java.lang.String getAnswer()
public boolean isSkip()
public int getType()
public java.lang.String getMp3url()
public int getWrongTime()
public int getWrongTimeTotalMilliseconds()
public int getWrongShow()
public int getStatus()
public long getCreatedTime()
public boolean isFromDownload()
public java.lang.String getWrongAnswer()
public java.lang.String getIllustration()
public boolean illustrationIsEmpty()
public java.lang.String toString()
toString
在类中 java.lang.Object
@Deprecated public static java.util.List<PolyvQuestionVO> formatQuestion(java.lang.String body, boolean isFromDownload) throws org.json.JSONException
body
- isFromDownload
- org.json.JSONException
formatJSONObject(JSONArray, boolean)
public static java.util.List<PolyvQuestionVO> formatJSONObject(org.json.JSONArray jsonArray, boolean isFromDownload)
jsonArray
- isFromDownload
- public static QuestionVO copyToQuestion(PolyvQuestionVO questionVO)