Class: Meibo::Builder
- Inherits:
-
Object
show all
- Extended by:
- Forwardable
- Defined in:
- lib/meibo/builder.rb,
lib/meibo/builder/base_builder.rb,
lib/meibo/builder/role_builder.rb,
lib/meibo/builder/user_builder.rb,
lib/meibo/builder/course_builder.rb,
lib/meibo/builder/classroom_builder.rb,
lib/meibo/builder/enrollment_builder.rb,
lib/meibo/builder/demographic_builder.rb,
lib/meibo/builder/organization_builder.rb,
lib/meibo/builder/user_profile_builder.rb,
lib/meibo/builder/academic_session_builder.rb
Defined Under Namespace
Modules: AcademicSessionBuilder, BaseBuilder, ClassroomBuilder, CourseBuilder, DemographicBuilder, EnrollmentBuilder, OrganizationBuilder, RoleBuilder, UserBuilder, UserProfileBuilder
Instance Attribute Summary collapse
Instance Method Summary
collapse
Constructor Details
#initialize(roster:, profile: Meibo.current_profile) ⇒ Builder
Returns a new instance of Builder.
14
15
16
17
|
# File 'lib/meibo/builder.rb', line 14
def initialize(roster:, profile: Meibo.current_profile)
@roster = roster
@profile = profile
end
|
Instance Attribute Details
#profile ⇒ Object
Returns the value of attribute profile.
9
10
11
|
# File 'lib/meibo/builder.rb', line 9
def profile
@profile
end
|
#roster ⇒ Object
Returns the value of attribute roster.
9
10
11
|
# File 'lib/meibo/builder.rb', line 9
def roster
@roster
end
|
Instance Method Details
#build_academic_session(**kw) ⇒ Object
19
20
21
|
# File 'lib/meibo/builder.rb', line 19
def build_academic_session(**kw)
builder_for(:academic_session).new(builder: self, **kw)
end
|
#build_classroom(**kw) ⇒ Object
23
24
25
|
# File 'lib/meibo/builder.rb', line 23
def build_classroom(**kw)
builder_for(:class).new(builder: self, **kw)
end
|
#build_course(**kw) ⇒ Object
27
28
29
|
# File 'lib/meibo/builder.rb', line 27
def build_course(**kw)
builder_for(:course).new(builder: self, **kw)
end
|
#build_demographic(**kw) ⇒ Object
31
32
33
|
# File 'lib/meibo/builder.rb', line 31
def build_demographic(**kw)
builder_for(:demographic).new(builder: self, **kw)
end
|
#build_enrollment(**kw) ⇒ Object
35
36
37
|
# File 'lib/meibo/builder.rb', line 35
def build_enrollment(**kw)
builder_for(:enrollment).new(builder: self, **kw)
end
|
#build_organization(**kw) ⇒ Object
39
40
41
|
# File 'lib/meibo/builder.rb', line 39
def build_organization(**kw)
builder_for(:org).new(builder: self, **kw)
end
|
#build_role(**kw) ⇒ Object
43
44
45
|
# File 'lib/meibo/builder.rb', line 43
def build_role(**kw)
builder_for(:role).new(builder: self, **kw)
end
|
#build_user(**kw) ⇒ Object
47
48
49
|
# File 'lib/meibo/builder.rb', line 47
def build_user(**kw)
builder_for(:user).new(builder: self, **kw)
end
|
#build_user_profile(**kw) ⇒ Object
51
52
53
|
# File 'lib/meibo/builder.rb', line 51
def build_user_profile(**kw)
builder_for(:user_profile).new(builder: self, **kw)
end
|