James Moger
2011-12-22 e6935876b97a63bae2ec087b4fc390c832aef155
commit | author | age
31abc2 1 /*
JM 2  * Copyright 2011 gitblit.com.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *     http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 package com.gitblit.models;
17
18 import java.io.Serializable;
19 import java.util.Map;
20
21 import com.gitblit.Constants.FederationToken;
22
23 /**
24  * Represents a group of repositories.
25  */
26 public class FederationSet implements Serializable {
27
28     private static final long serialVersionUID = 1L;
29
30     public String name;
31
32     public String token;
33
34     public FederationToken tokenType;
35
36     public Map<String, RepositoryModel> repositories;
37
38     /**
39      * The constructor for a federation set.
40      * 
41      * @param name
42      *            the name of this federation set
43      * @param tokenType
44      *            the type of token of this federation set
45      * @param token
46      *            the federation token
47      */
48     public FederationSet(String name, FederationToken tokenType, String token) {
49         this.name = name;
50         this.tokenType = tokenType;
51         this.token = token;
52     }
53
54     @Override
55     public String toString() {
56         return "Federation Set (" + name + ")";
57     }
58 }