blob: a4934759714e1f4c957960020307852c37e554fb [file] [log] [blame]
srikanth116e6e82014-08-19 07:22:37 -07001#
2# Copyright (c) 2013 Big Switch Networks, Inc.
3#
4# Licensed under the Eclipse Public License, Version 1.0 (the
5# "License"); you may not use this file except in compliance with the
6# License. You may obtain a copy of the License at
7#
8# http://www.eclipse.org/legal/epl-v10.html
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
13# implied. See the License for the specific language governing
14# permissions and limitations under the License.
15#
16
17from django.db import models
Srikanth Vavilapalli669ba8a2014-10-16 11:41:19 -070018"""
srikanth116e6e82014-08-19 07:22:37 -070019class StatdConfig(models.Model):
20 stat_type = models.CharField(
21 primary_key=True,
22 verbose_name='Stat Type',
23 max_length=64)
24
25 sampling_period = models.PositiveIntegerField(
26 verbose_name='Sampling Period',
27 default=15)
28
29 reporting_period = models.PositiveIntegerField(
30 verbose_name='Reporting Period',
31 default=60)
32
33 class Rest:
34 NAME = 'statd-config'
35 FIELD_INFO = (
36 {'name': 'stat_type', 'rest_name': 'stat-type'},
37 {'name': 'sampling_period', 'rest_name': 'sampling-period'},
38 {'name': 'reporting_period', 'rest_name': 'reporting-period'},
39 )
Srikanth Vavilapalli669ba8a2014-10-16 11:41:19 -070040"""