コード例 #1
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                var match = PrivateMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content);
                var url   = string.Format("http://www.google.com/ig/calculator?hl=en&q={0}", Uri.EscapeDataString(match.Groups[3].Value));

                var client = new HttpClient();
                client.Timeout = new TimeSpan(0, 0, 2);
                client.DefaultRequestHeaders.AcceptLanguage.Add(new StringWithQualityHeaderValue("en-us"));
                client.DefaultRequestHeaders.AcceptCharset.Add(new StringWithQualityHeaderValue("utf-8"));
                var request = client.GetAsync(url).ContinueWith(requestTask =>
                {
                    if (requestTask.Result.IsSuccessStatusCode)
                    {
                        requestTask.Result.Content.ReadAsStringAsync().ContinueWith(readTask =>
                        {
                            dynamic json    = JsonConvert.DeserializeObject(readTask.Result);
                            string solution = json.rhs;
                            jabbrClient.SayToRoom(message.Room, solution ?? "Does not compute.");
                        });
                    }
                    else
                    {
                        jabbrClient.SayToRoom(message.Room, "Does not compute.");
                    }
                });
            }
        }
コード例 #2
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                var match = RoomMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content);
                var text  = Uri.EscapeUriString(match.Groups[3].Value);

                var client = new HttpClient();
                client.DefaultRequestHeaders.AcceptLanguage.Add(new StringWithQualityHeaderValue("en-us"));
                client.DefaultRequestHeaders.AcceptCharset.Add(new StringWithQualityHeaderValue("utf-8"));
                client.GetAsync(String.Format(Url, text)).ContinueWith(task =>
                {
                    if (task.Result.IsSuccessStatusCode)
                    {
                        task.Result.Content.ReadAsStringAsync().ContinueWith(readTask =>
                        {
                            jabbrClient.SayToRoom(message.Room, readTask.Result);
                        });
                    }
                    else
                    {
                        jabbrClient.PrivateReply(message.From, "Error ascii'ing that for you.");
                    }
                });
            }
        }
コード例 #3
0
        public override void Handle(IPrivateMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                if (PrivateMessagePatterns.First().Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, this.GetFormattedHelp());
                }
                else if (PrivateMessagePatterns.ElementAt(1).Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, "pong");
                }
                else if (PrivateMessagePatterns.ElementAt(2).Match(message.Content).Success)
                {
                    var match = PrivateMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content);
                    jabbrClient.PrivateReply(message.From, match.Groups[2].Value);
                }
                else if (PrivateMessagePatterns.ElementAt(3).Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, String.Format("{0:F} UTC", DateTimeOffset.UtcNow));
                }
                else if (PrivateMessagePatterns.ElementAt(4).Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, String.Format("I'm sorry, {0}. I'm afraid I can't do that.", message.From));
                }
            }
        }
コード例 #4
0
ファイル: PingSprocket.cs プロジェクト: rbwestmoreland/Jabbot
        public override void Handle(IPrivateMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                if (PrivateMessagePatterns.First().Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, this.GetFormattedHelp());
                }
                else if (PrivateMessagePatterns.ElementAt(1).Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, "pong");
                }
                else if (PrivateMessagePatterns.ElementAt(2).Match(message.Content).Success)
                {
                    var match = PrivateMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content);
                    jabbrClient.PrivateReply(message.From, match.Groups[2].Value);
                }
                else if (PrivateMessagePatterns.ElementAt(3).Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, String.Format("{0:F} UTC", DateTimeOffset.UtcNow));
                }
                else if (PrivateMessagePatterns.ElementAt(4).Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, String.Format("I'm sorry, {0}. I'm afraid I can't do that.", message.From));
                }
            }
        }
コード例 #5
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                jabbrClient.SayToRoom(message.Room, Carltons.RandomElement());
            }
        }
コード例 #6
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                var formattedInformation = GetFormattedInformation();
                jabbrClient.SayToRoom(message.Room, formattedInformation);
            }
        }
コード例 #7
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                var formattedInformation = GetFormattedInformation();
                jabbrClient.SayToRoom(message.Room, formattedInformation);
            }
        }
コード例 #8
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                var id  = RoomMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content).Groups[2].Value;
                var url = string.IsNullOrWhiteSpace(id) ? GetRandomUrl() : GetComicUrl(id);
                jabbrClient.SayToRoom(message.Room, url);
            }
        }
コード例 #9
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                var location             = RoomMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content).Groups[3].Value;
                var formattedInformation = GetWeather(location);
                jabbrClient.SayToRoom(message.Room, formattedInformation);
            }
        }
コード例 #10
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                var match   = PrivateMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content);
                var choices = match.Groups[1].Value.Split(new string[] { "\"" }, StringSplitOptions.None).Where(s => !string.IsNullOrWhiteSpace(s));
                jabbrClient.SayToRoom(message.Room, choices.RandomElement());
            }
        }
コード例 #11
0
ファイル: BaseSprocket.cs プロジェクト: rbwestmoreland/Jabbot
        public virtual void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            if (message == null)
            {
                throw new ArgumentNullException("message");
            }

            if (jabbrClient == null)
            {
                throw new ArgumentNullException("jabbrClient");
            }
        }
コード例 #12
0
        public override void Handle(IPrivateMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                if (PrivateMessagePatterns.First().Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, this.GetFormattedHelp());
                }
            }
        }
コード例 #13
0
        public virtual void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            if (message == null)
            {
                throw new ArgumentNullException("message");
            }

            if (jabbrClient == null)
            {
                throw new ArgumentNullException("jabbrClient");
            }
        }
コード例 #14
0
        public override void Handle(IPrivateMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                if (PrivateMessagePatterns.First().Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, this.GetFormattedHelp());
                }
            }
        }
コード例 #15
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                foreach (var rule in Rules)
                {
                    jabbrClient.SayToRoom(message.Room, rule);
                }
            }
        }
コード例 #16
0
ファイル: RoomSprocket.cs プロジェクト: rbwestmoreland/Jabbot
        public override void Handle(IPrivateMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                if (PrivateMessagePatterns.First().Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, this.GetFormattedHelp());
                }
                else if (PrivateMessagePatterns.ElementAt(1).Match(message.Content).Success)
                {
                    var match = PrivateMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content);
                    var room = match.Groups[1].Value;
                    var invitecode = match.Groups[3].Value;

                    if (string.IsNullOrWhiteSpace(invitecode))
                    {
                        if (jabbrClient.JoinRoom(room))
                        {
                            jabbrClient.SayToRoom(room, Greetings.RandomElement());
                        }
                        else
                        {
                            jabbrClient.PrivateReply(message.From, string.Format("Unable to join room {0}. If the room is private, make sure to /allow [botname] [room] or use /msg [botname] join room [room] [invitecode]", room));
                        }
                    }
                    else
                    {
                        if (jabbrClient.JoinRoom(room, invitecode))
                        {
                            jabbrClient.SayToRoom(room, Greetings.RandomElement());
                        }
                        else
                        {
                            jabbrClient.PrivateReply(message.From, string.Format("Unable to join room {0}. The invite code {1} is invalid.", room, invitecode));
                        }
                    }
                }
                else if (PrivateMessagePatterns.ElementAt(2).Match(message.Content).Success)
                {
                    var match = PrivateMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content);
                    var room = match.Groups[2].Value;
                    jabbrClient.SayToRoom(room, Farewells.RandomElement());
                    if (!jabbrClient.LeaveRoom(room))
                    {
                        jabbrClient.PrivateReply(message.From, string.Format("Unable to leave room {0}.", room));
                    }
                }
            }
        }
コード例 #17
0
        public override void Handle(IPrivateMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                if (PrivateMessagePatterns.First().Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, this.GetFormattedHelp());
                }
                else if (PrivateMessagePatterns.ElementAt(1).Match(message.Content).Success)
                {
                    var match      = PrivateMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content);
                    var room       = match.Groups[1].Value;
                    var invitecode = match.Groups[3].Value;

                    if (string.IsNullOrWhiteSpace(invitecode))
                    {
                        if (jabbrClient.JoinRoom(room))
                        {
                            jabbrClient.SayToRoom(room, Greetings.RandomElement());
                        }
                        else
                        {
                            jabbrClient.PrivateReply(message.From, string.Format("Unable to join room {0}. If the room is private, make sure to /allow [botname] [room] or use /msg [botname] join room [room] [invitecode]", room));
                        }
                    }
                    else
                    {
                        if (jabbrClient.JoinRoom(room, invitecode))
                        {
                            jabbrClient.SayToRoom(room, Greetings.RandomElement());
                        }
                        else
                        {
                            jabbrClient.PrivateReply(message.From, string.Format("Unable to join room {0}. The invite code {1} is invalid.", room, invitecode));
                        }
                    }
                }
                else if (PrivateMessagePatterns.ElementAt(2).Match(message.Content).Success)
                {
                    var match = PrivateMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content);
                    var room  = match.Groups[2].Value;
                    jabbrClient.SayToRoom(room, Farewells.RandomElement());
                    if (!jabbrClient.LeaveRoom(room))
                    {
                        jabbrClient.PrivateReply(message.From, string.Format("Unable to leave room {0}.", room));
                    }
                }
            }
        }
コード例 #18
0
        public override void Handle(IPrivateMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                if (PrivateMessagePatterns.First().Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, this.GetFormattedHelp());
                }
                else
                {
                    var id  = PrivateMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content).Groups[2].Value;
                    var url = string.IsNullOrWhiteSpace(id) ? GetRandomUrl() : GetComicUrl(id);
                    jabbrClient.PrivateReply(message.From, url);
                }
            }
        }
コード例 #19
0
        public override void Handle(IPrivateMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                if (PrivateMessagePatterns.First().Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, this.GetFormattedHelp());
                }
                else
                {
                    var match = PrivateMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content);
                    var choices = match.Groups[1].Value.Split(new string[] { "\"" }, StringSplitOptions.None).Where(s => !string.IsNullOrWhiteSpace(s));
                    jabbrClient.PrivateReply(message.From, choices.RandomElement());
                }
            }
        }
コード例 #20
0
        public override void Handle(IPrivateMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                if (PrivateMessagePatterns.First().Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, this.GetFormattedHelp());
                }
                else
                {
                    var location             = PrivateMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content).Groups[3].Value;
                    var formattedInformation = GetWeather(location);
                    jabbrClient.PrivateReply(message.From, formattedInformation);
                }
            }
        }
コード例 #21
0
        public override void Handle(IPrivateMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                if (PrivateMessagePatterns.First().Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, this.GetFormattedHelp());
                }
                else
                {
                    var location = PrivateMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content).Groups[3].Value;
                    var formattedInformation = GetWeather(location);
                    jabbrClient.PrivateReply(message.From, formattedInformation);
                }
            }
        }
コード例 #22
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                Task.Factory.StartNew(() =>
                {
                    var match           = RoomMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content);
                    var imageUrl        = match.Groups[2].Value;
                    var stachedImageUrl = String.Format("http://faceup.me/img.jpg?overlay={0}&src={1}", Accessories.RandomElement(), Uri.EscapeDataString(imageUrl));

                    jabbrClient.SayToRoom(message.Room, stachedImageUrl);
                }).ContinueWith(task =>
                {
                    var result = task.Exception;
                },
                                TaskContinuationOptions.OnlyOnFaulted);
            }
        }
コード例 #23
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                var match       = RoomMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content);
                var achievement = Uri.EscapeUriString(match.Groups[2].Value);
                var email       = Uri.EscapeUriString(match.Groups[5].Value);

                var url = String.Format(Url, achievement);

                if (!String.IsNullOrWhiteSpace(email))
                {
                    url += String.Format("?email={0}.png", email);
                }

                jabbrClient.SayToRoom(message.Room, url);
            }
        }
コード例 #24
0
ファイル: MathSprocket.cs プロジェクト: rbwestmoreland/Jabbot
        public override void Handle(IPrivateMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                if (PrivateMessagePatterns.First().Match(message.Content).Success)
                {
                    jabbrClient.PrivateReply(message.From, this.GetFormattedHelp());
                }
                else
                {
                    var match = PrivateMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content);
                    var url = string.Format("http://www.google.com/ig/calculator?hl=en&q={0}", Uri.EscapeDataString(match.Groups[3].Value));

                    var client = new HttpClient();
                    client.Timeout = new TimeSpan(0, 0, 2);
                    client.DefaultRequestHeaders.AcceptLanguage.Add(new StringWithQualityHeaderValue("en-us"));
                    client.DefaultRequestHeaders.AcceptCharset.Add(new StringWithQualityHeaderValue("utf-8"));
                    var request = client.GetAsync(url).ContinueWith(requestTask =>
                          {
                              if (requestTask.Result.IsSuccessStatusCode)
                              {
                                  requestTask.Result.Content.ReadAsStringAsync().ContinueWith(readTask =>
                                  {
                                      dynamic json = JsonConvert.DeserializeObject(readTask.Result);
                                      string solution = json.rhs;
                                      jabbrClient.PrivateReply(message.From, solution ?? "Does not compute.");
                                  });
                              }
                              else
                              {
                                  jabbrClient.PrivateReply(message.From, "Does not compute.");
                              }
                          });
                }
            }
        }
コード例 #25
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                if (RoomMessagePatterns.ElementAt(0).IsMatch(message.Content))
                {
                    jabbrClient.SayToRoom(message.Room, new string[] { "(ノಠ益ಠ)ノ︵┻━┻", "(╯°□°)╯︵ ┻━┻" }.RandomElement());
                }
                else if (RoomMessagePatterns.ElementAt(1).IsMatch(message.Content))
                {
                    jabbrClient.SayToRoom(message.Room, "┬──┬◡ノ(° -°ノ)");
                }
                else if (RoomMessagePatterns.ElementAt(2).IsMatch(message.Content))
                {
                    jabbrClient.SayToRoom(message.Room, "(ケ¬◟¬)ケ");
                }
                else if (RoomMessagePatterns.ElementAt(3).IsMatch(message.Content))
                {
                    jabbrClient.SayToRoom(message.Room, "ლ(ಠ益ಠლ)");
                }
                else if (RoomMessagePatterns.ElementAt(4).IsMatch(message.Content))
                {
                    jabbrClient.SayToRoom(message.Room, new string[] { "♪┏(・o・)┛♪", "♪┗ ( ・o・) ┓♪", "♪┏ (・o・) ┛♪", "♪┗ (・o・ ) ┓♪", "♪┏(・o・)┛♪" }.RandomElement());
                }
                else if (RoomMessagePatterns.ElementAt(5).IsMatch(message.Content))
                {
                    jabbrClient.SayToRoom(message.Room, "ಠ_ಠ");
                }
                else if (RoomMessagePatterns.ElementAt(6).IsMatch(message.Content))
                {
                    jabbrClient.SayToRoom(message.Room, @"¯\_(ツ)_/¯");
                }
            }
        }
コード例 #26
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                foreach (var rule in Rules)
                {
                    jabbrClient.SayToRoom(message.Room, rule);
                }
            }
        }
コード例 #27
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                var match = RoomMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content);
                var achievement = Uri.EscapeUriString(match.Groups[2].Value);
                var email = Uri.EscapeUriString(match.Groups[5].Value);

                var url = String.Format(Url, achievement);

                if (!String.IsNullOrWhiteSpace(email))
                {
                    url += String.Format("?email={0}.png", email);
                }

                jabbrClient.SayToRoom(message.Room, url);
            }
        }
コード例 #28
0
ファイル: HelpSprocket.cs プロジェクト: rbwestmoreland/Jabbot
 public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
 {
     base.Handle(message, jabbrClient);
 }
コード例 #29
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                var location = RoomMessagePatterns.First(p => p.Match(message.Content).Success).Match(message.Content).Groups[3].Value;
                var formattedInformation = GetWeather(location);
                jabbrClient.SayToRoom(message.Room, formattedInformation);
            }
        }
コード例 #30
0
 public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
 {
     base.Handle(message, jabbrClient);
 }
コード例 #31
0
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                if (RoomMessagePatterns.ElementAt(0).IsMatch(message.Content))
                {
                    jabbrClient.SayToRoom(message.Room, new string[] { "(ノಠ益ಠ)ノ︵┻━┻", "(╯°□°)╯︵ ┻━┻" }.RandomElement());
                }
                else if (RoomMessagePatterns.ElementAt(1).IsMatch(message.Content))
                {
                    jabbrClient.SayToRoom(message.Room, "┬──┬◡ノ(° -°ノ)");
                }
                else if (RoomMessagePatterns.ElementAt(2).IsMatch(message.Content))
                {
                    jabbrClient.SayToRoom(message.Room, "(ケ¬◟¬)ケ");
                }
                else if (RoomMessagePatterns.ElementAt(3).IsMatch(message.Content))
                {
                    jabbrClient.SayToRoom(message.Room, "ლ(ಠ益ಠლ)");
                }
                else if (RoomMessagePatterns.ElementAt(4).IsMatch(message.Content))
                {
                    jabbrClient.SayToRoom(message.Room, new string[] { "♪┏(・o・)┛♪", "♪┗ ( ・o・) ┓♪", "♪┏ (・o・) ┛♪", "♪┗ (・o・ ) ┓♪", "♪┏(・o・)┛♪" }.RandomElement());
                }
                else if (RoomMessagePatterns.ElementAt(5).IsMatch(message.Content))
                {
                    jabbrClient.SayToRoom(message.Room, "ಠ_ಠ");
                }
                else if (RoomMessagePatterns.ElementAt(6).IsMatch(message.Content))
                {
                    jabbrClient.SayToRoom(message.Room, @"¯\_(ツ)_/¯");
                }
            }
        }
コード例 #32
0
ファイル: CoinSprocket.cs プロジェクト: rbwestmoreland/Jabbot
        public override void Handle(IRoomMessage message, IJabbrClient jabbrClient)
        {
            base.Handle(message, jabbrClient);

            if (this.CanHandle(message))
            {
                jabbrClient.SayToRoom(message.Room, Coin.RandomElement());
            }
        }