-
Notifications
You must be signed in to change notification settings - Fork 32
Expand file tree
/
Copy pathLibrary.cs
More file actions
32 lines (28 loc) · 821 Bytes
/
Library.cs
File metadata and controls
32 lines (28 loc) · 821 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
namespace Exercise
{
public sealed class Library
{
//implement Singleton to make sure only one library will exist
private static Library instance;
private Library() { }
public static Library Instance
{
get
{
if (instance == null)
{
instance = new Library();
}
return instance;
}
}
//public static Library getInstance() ()
//Implement Register method by utilizing RegistrationRepository (complete missing parts)
public int Register(IRegistarable newRegObject)
{
return RegistrationRepository.Register(newRegObject);
//dummy, just to compile
//return 0;
}
}
}