~ubuntu-branches/ubuntu/lucid/gnome-subtitles/lucid

« back to all changes in this revision

Viewing changes to sublib-0.8/src/SubLib/Application/SubtitleSearchResults.cs

  • Committer: Bazaar Package Importer
  • Author(s): Tiago Bortoletto Vaz
  • Date: 2007-12-03 20:52:52 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20071203205252-2y6uuv4gcw9mi9n5
Tags: 0.7-1
* New upstream release;
* Add libxml-parser-perl to Build-Depends-Indep. Thanks to Lucas Nussbaum.
  (Closes: #445799);
* Fixes manpage issue with dpatch

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * This file is part of SubLib.
 
3
 * Copyright (C) 2007 Pedro Castro
 
4
 *
 
5
 * SubLib is free software; you can redistribute it and/or modify
 
6
 * it under the terms of the GNU General Public License as published by
 
7
 * the Free Software Foundation; either version 2 of the License, or
 
8
 * (at your option) any later version.
 
9
 *
 
10
 * SubLib is distributed in the hope that it will be useful,
 
11
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
12
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 
13
 * GNU General Public License for more details.
 
14
 *
 
15
 * You should have received a copy of the GNU General Public License
 
16
 * along with this program; if not, write to the Free Software
 
17
 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
 
18
 */
 
19
 
 
20
using System;
 
21
 
 
22
namespace SubLib {
 
23
 
 
24
/// <summary>Represents the results of a search operation.</summary>
 
25
public class SubtitleSearchResults {
 
26
        private int subtitle = -1;
 
27
        private SubtitleTextType textType = SubtitleTextType.Text;
 
28
        private int index = -1;
 
29
        private int length = -1;
 
30
 
 
31
        /// <summary>Creates a new instance of the <see cref="SubtitleSearchResults" /> class.</summary>
 
32
        /// <param name="subtitle">The zero-based number of the subtitle where the text was found.</param>
 
33
        /// <param name="textType">The type of text content where the text was found.</param>
 
34
        /// <param name="index">The zero-based position where the text was found, within a subtitle.</param>
 
35
        /// <param name="length">The length of the found text.</param>
 
36
        public SubtitleSearchResults (int subtitle, SubtitleTextType textType, int index, int length) {
 
37
                this.subtitle = subtitle;
 
38
                this.textType = textType;
 
39
                this.index = index;
 
40
                this.length = length;
 
41
        }
 
42
        
 
43
        /* Public properties */
 
44
        
 
45
        /// <summary>The subtitle number.</summary>
 
46
        public int Subtitle {
 
47
                get { return subtitle; }
 
48
        }
 
49
        
 
50
        /// <summary>The type of the text content.</summary>
 
51
        public SubtitleTextType TextType {
 
52
                get { return textType; }
 
53
        }
 
54
        
 
55
        /// <summary>The text index.</summary>
 
56
        public int Index {
 
57
                get { return index; }
 
58
        }
 
59
        
 
60
        /// <summary>The text length.</summary>
 
61
        public int Length {
 
62
                get { return length; }
 
63
        }
 
64
 
 
65
}
 
66
 
 
67
}