src/group/fieldset.model.ts
Methods |
|
constructor(code: string, description: string, questions: Question[])
|
||||||||||||||||
Defined in src/group/fieldset.model.ts:4
|
||||||||||||||||
Parameters :
|
Public getQuestionByName | ||||||||
getQuestionByName(name: string)
|
||||||||
Defined in src/group/fieldset.model.ts:14
|
||||||||
Parameters :
Returns :
Question<any>
|
import { Group, GroupType } from '.';
import { Question } from '../question';
export class Fieldset extends Group<Question<any>[]> {
public constructor(
code: string,
description: string,
questions: Question<any>[]
) {
super(code, description, GroupType.FIELDSET, questions);
}
public getQuestionByName(name: string): Question<any> {
for (const question of this.questions) {
if (question.name === name) {
return question;
}
}
}
}