~ubuntu-branches/ubuntu/trusty/smuxi/trusty-proposed

« back to all changes in this revision

Viewing changes to lib/db4o-net/Db4objects.Db4o.NativeQueries/Db4objects.Db4o.NativeQueries/Expr/Cmp/ArithmeticOperator.cs

  • Committer: Package Import Robot
  • Author(s): Mirco Bauer
  • Date: 2013-05-25 22:11:31 UTC
  • mfrom: (1.2.12)
  • Revision ID: package-import@ubuntu.com-20130525221131-nd2mc0kzubuwyx20
Tags: 0.8.11-1
* [22d13d5] Imported Upstream version 0.8.11
* [6d2b95a] Refreshed patches
* [89eb66e] Added ServiceStack libraries to smuxi-engine package
* [848ab10] Enable Campfire engine
* [c6dbdc7] Always build db4o for predictable build result
* [13ec489] Exclude OS X specific libraries from dh_clideps

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* Copyright (C) 2004 - 2009  Versant Inc.  http://www.db4o.com */
2
 
 
3
 
namespace Db4objects.Db4o.NativeQueries.Expr.Cmp
4
 
{
5
 
        public sealed class ArithmeticOperator
6
 
        {
7
 
                public const int AddId = 0;
8
 
 
9
 
                public const int SubtractId = 1;
10
 
 
11
 
                public const int MultiplyId = 2;
12
 
 
13
 
                public const int DivideId = 3;
14
 
 
15
 
                public static readonly Db4objects.Db4o.NativeQueries.Expr.Cmp.ArithmeticOperator 
16
 
                        Add = new Db4objects.Db4o.NativeQueries.Expr.Cmp.ArithmeticOperator(AddId, "+");
17
 
 
18
 
                public static readonly Db4objects.Db4o.NativeQueries.Expr.Cmp.ArithmeticOperator 
19
 
                        Subtract = new Db4objects.Db4o.NativeQueries.Expr.Cmp.ArithmeticOperator(SubtractId
20
 
                        , "-");
21
 
 
22
 
                public static readonly Db4objects.Db4o.NativeQueries.Expr.Cmp.ArithmeticOperator 
23
 
                        Multiply = new Db4objects.Db4o.NativeQueries.Expr.Cmp.ArithmeticOperator(MultiplyId
24
 
                        , "*");
25
 
 
26
 
                public static readonly Db4objects.Db4o.NativeQueries.Expr.Cmp.ArithmeticOperator 
27
 
                        Divide = new Db4objects.Db4o.NativeQueries.Expr.Cmp.ArithmeticOperator(DivideId, 
28
 
                        "/");
29
 
 
30
 
                private string _op;
31
 
 
32
 
                private int _id;
33
 
 
34
 
                private ArithmeticOperator(int id, string op)
35
 
                {
36
 
                        _id = id;
37
 
                        _op = op;
38
 
                }
39
 
 
40
 
                public int Id()
41
 
                {
42
 
                        return _id;
43
 
                }
44
 
 
45
 
                public override string ToString()
46
 
                {
47
 
                        return _op;
48
 
                }
49
 
        }
50
 
}