|
1 |
| package com.agical.rdoc.core.impl; |
|
2 |
| |
|
3 |
| import java.io.Serializable; |
|
4 |
| import java.util.HashMap; |
|
5 |
| import java.util.Map; |
|
6 |
| |
|
7 |
| import com.agical.rdoc.core.DocumentationContext; |
|
8 |
| |
|
9 |
| public class DocumentationContextImpl implements DocumentationContext { |
|
10 |
| private static final long serialVersionUID = 1L; |
|
11 |
| private final Map context = new HashMap(); |
|
12 |
1
| public void put(String name, Serializable serializable) {
|
|
13 |
1
| context.put(name, serializable);
|
|
14 |
| |
|
15 |
| } |
|
16 |
| |
|
17 |
1
| public Serializable get(String name) {
|
|
18 |
1
| return (Serializable) context.get(name);
|
|
19 |
| } |
|
20 |
| |
|
21 |
514
| public boolean equals(Object obj) {
|
|
22 |
514
| if (obj instanceof DocumentationContextImpl) {
|
|
23 |
514
| DocumentationContextImpl documentationContextImpl = (DocumentationContextImpl) obj;
|
|
24 |
514
| documentationContextImpl.context.equals(this.context);
|
|
25 |
| } |
|
26 |
514
| return super.equals(obj);
|
|
27 |
| } |
|
28 |
| |
|
29 |
0
| public String toString() {
|
|
30 |
0
| return context.toString();
|
|
31 |
| } |
|
32 |
| } |