Ejemplo n.º 1
0
        public void AddTagAction(string itemId, string tag, TagActionKind kind)
        {
            using (var connection = new SQLiteConnection(DatabaseFilename))
            {
                using (
                    var statement =
                        connection.Prepare(@"INSERT INTO TAG_ACTION(ITEM_ID, TAG, ACTION_KIND) VALUES(@ITEM_ID, @TAG, @ACTION_KIND);"))
                {
                    statement.Bind("@ITEM_ID", itemId);
                    statement.Bind("@TAG", tag);
                    statement.Bind("@ACTION_KIND", (int)kind);

                    statement.Step();
                }
            }
        }
Ejemplo n.º 2
0
		public void AddTagAction(string itemId, string tag, TagActionKind kind)
		{
			using (var connection = new SQLiteConnection(DatabaseFilename))
			{
				using (
					var statement =
						connection.Prepare(@"INSERT INTO TAG_ACTION(ITEM_ID, TAG, ACTION_KIND) VALUES(@ITEM_ID, @TAG, @ACTION_KIND);"))
				{
					statement.Bind("@ITEM_ID", itemId);
					statement.Bind("@TAG", tag);
					statement.Bind("@ACTION_KIND", (int)kind);

					statement.Step();
				}
			}
		}