internal Picture(BuddyClient client, AuthenticatedUser user, InternalModels.DataContract_PhotoList photo) : base(client, photo.FullPhotoURL, photo.ThumbnailPhotoURL, client.TryParseDouble(photo.Latitude), client.TryParseDouble(photo.Longitude), photo.PhotoComment, photo.ApplicationTag, photo.AddedDateTime, Int32.Parse(photo.PhotoID), user) { }
internal Message(InternalModels.DataContract_MessagesFromMe msg, int fromId) { this.DateSent = msg.DateSent; this.FromUserID = fromId; this.ToUserID = Int32.Parse(msg.ToUserID); this.Text = msg.MessageString; }
internal MetroArea(BuddyClient client, AuthenticatedUser user, InternalModels.DataContract_MetroList metro) : base(client, user) { this.MetroName = metro.MetroName; this.ImageURL = metro.ImageURL; }
public ConfigType GetConfigType(ConfigCode configCode) { ConfigItem configItem = InternalModels.FirstOrDefault((c) => (c.Key == configCode)).Value; if (configItem == null) { return((ConfigType)ArticleType.NO_HEAD_PART_TYPE); } return(configItem.Type()); }
public ConfigBind GetConfigBind(ConfigCode configCode) { ConfigItem configItem = InternalModels.FirstOrDefault((c) => (c.Key == configCode)).Value; if (configItem == null) { return((ConfigBind)ArticleBind.ARTICLE_OPT); } return(configItem.Bind()); }
internal GroupMessage(BuddyClient client, InternalModels.DataContract_GroupMessage msg, MessageGroup group) { this.DateSent = Convert.ToDateTime(msg.SentDateTime, CultureInfo.InvariantCulture); this.Group = group; this.Latitude = client.TryParseDouble(msg.Latitude); this.Longitude = client.TryParseDouble(msg.Longitude); this.FromUserID = Int32.Parse(msg.FromUserID); this.Text = msg.MessageText; }
internal RegisteredDeviceApple(InternalModels.DataContract_AppleDeviceList device, AuthenticatedUser user) { if (device == null) throw new ArgumentNullException("device"); if (user == null) throw new ArgumentNullException("user"); this.UserID = Int32.Parse(device.UserID); this.APNSDeviceToken = device.APNSDeviceToken; this.GroupName = device.GroupName; this.LastUpdateDate = device.DeviceModified; this.RegistrationDate = device.DeviceRegistered; this.User = user; }
internal MessageGroup (BuddyClient client, AuthenticatedUser user, InternalModels.DataContract_GroupChatMemberships group) : base(client, user) { this.ID = Int32.Parse (group.ChatGroupID); this.Name = group.ChatGroupName; this.CreatedOn = Convert.ToDateTime (group.CreatedDateTime, CultureInfo.InvariantCulture); this.AppTag = group.ApplicationTag; this.OwnerUserID = Int32.Parse (group.OwnerUserID); this.MemberUserIDs = new List<int> (); foreach (string id in group.MemberUserIDList.Split(';')) this.MemberUserIDs.Add (Int32.Parse (id)); }
internal Blob(BuddyClient client, AuthenticatedUser user, InternalModels.DataContract_Blob blob) : base(client, user) { this.BlobID = long.Parse(blob.BlobID, CultureInfo.InvariantCulture); this.FriendlyName = blob.FriendlyName; this.MimeType = blob.MimeType; this.FileSize = int.Parse(blob.FileSize, CultureInfo.InvariantCulture); this.AppTag = blob.AppTag; this.Owner = long.Parse(blob.Owner, CultureInfo.InvariantCulture); this.Latitude = double.Parse(blob.Latitude, CultureInfo.InvariantCulture); this.Longitude = double.Parse(blob.Longitude, CultureInfo.InvariantCulture); this.UploadDate = blob.UploadDate; this.LastTouchDate = blob.LastTouchDate; }
internal GameState(InternalModels.DataContract_GameStateObject gs) { this.AppTag = gs.AppTag; this.Key = gs.StateKey; this.ID = Int32.Parse(gs.StateID); this.Value = gs.StateValue; DateTime dt; if (DateTime.TryParse(gs.StateDateTime, out dt)) { this.AddedOn = dt; } }
protected TConfig FindConfigByCode(TIndex configCode) { TConfig modelInstance = default(TConfig); if (InternalModels.ContainsKey(configCode)) { modelInstance = InternalModels[configCode]; } else { modelInstance = InternalModels[DefaultCode]; } return(modelInstance); }
protected void ConfigureModelDependency() { IDictionary <ConfigCode, ArticleReferenceSort <ConfigGang, ConfigCode> > resultsZero = new Dictionary <ConfigCode, ArticleReferenceSort <ConfigGang, ConfigCode> >(); InternalQueue = InternalModels.Aggregate(resultsZero, (agr, c) => agr.Merge(c.Value.Code(), c.Value.Gang(), ResolveDependencyPath(agr, c.Value.Code(), c.Value.Path(), InternalModels))); IList <ConfigCode> TempKeys = InternalModels.Keys.ToList(); IList <ConfigCode> SortKeys = TempKeys.OrderBy((x) => (x), new CompareConfigCode(InternalQueue)).ToList(); IList <KeyValuePair <ConfigCode, ConfigSort> > SortPair = SortKeys.Select((k, i) => (new KeyValuePair <ConfigCode, Int32>(k, i))).ToList(); InternalRanks = SortPair.ToDictionary(kv => kv.Key, kv => kv.Value); }
internal VirtualAlbum(BuddyClient client, AuthenticatedUser user, InternalModels.DataContract_VirtualPhotoAlbumInformation info) : base(client, user) { this.pictures = new List<PicturePublic> (); this.Pictures = new ReadOnlyCollection<PicturePublic> (this.pictures); this.ID = Int32.Parse (info.VirtualAlbumID); this.ApplicationTag = info.ApplicationTag; this.CreatedOn = Convert.ToDateTime (info.CreatedDateTime, CultureInfo.InvariantCulture); this.LastUpdated = Convert.ToDateTime (info.LastUpdatedDateTime, CultureInfo.InvariantCulture); this.Name = info.PhotoAlbumName; this.OwnerUserId = Int32.Parse (info.UserID); this.ThumbnailUrl = info.PhotoAlbumThumbnail; }
internal Video(BuddyClient client, AuthenticatedUser user, InternalModels.DataContract_Video video) : base(client, user) { this.VideoID = long.Parse(video.VideoID, CultureInfo.InvariantCulture); this.FriendlyName = video.FriendlyName; this.MimeType = video.MimeType; this.FileSize = int.Parse(video.FileSize, CultureInfo.InvariantCulture); this.AppTag = video.AppTag; this.Owner = long.Parse(video.Owner, CultureInfo.InvariantCulture); this.Latitude = double.Parse(video.Latitude, CultureInfo.InvariantCulture); this.Longitude = double.Parse(video.Longitude, CultureInfo.InvariantCulture); this.UploadDate = DateTime.Parse(video.UploadDate, CultureInfo.InvariantCulture); this.LastTouchDate = DateTime.Parse(video.LastTouchDate, CultureInfo.InvariantCulture); this.VideoUrl = video.VideoUrl; }
internal RegisteredDeviceWin8(InternalModels.DataContract_Win8DeviceList device, AuthenticatedUser user) { if (device == null) throw new ArgumentNullException("device"); if (user == null) throw new ArgumentNullException("user"); this.UserID = Int32.Parse(device.UserID); this.DeviceURI = device.DeviceURI; this.GroupName = device.GroupName; this.LastUpdateDate = device.DeviceModified; this.RegistrationDate = device.DeviceRegistered; this.ClientID = device.ClientID; this.ClientSecret = device.ClientSecret; this.User = user; }
internal RegisteredDevice(InternalModels.DataContract_WPDeviceList device, AuthenticatedUser user) { if (device == null) throw new ArgumentNullException("device"); if (user == null) throw new ArgumentNullException("user"); this.UserID = Int32.Parse(device.UserID); this.DeviceUri = device.DeviceURI; this.GroupName = device.GroupName; this.TilesEnabled = Boolean.Parse(device.EnableTiles); this.RawMessagesEnabled = Boolean.Parse(device.EnableRawMessages); this.ToastMessagesEnabled = Boolean.Parse(device.EnableToastMessages); this.LastUpdateDate = device.DeviceModified; this.RegistrationDate = device.DeviceRegistered; this.User = user; }
internal GamePlayer(BuddyClient client, AuthenticatedUser user, InternalModels.DataContract_GamePlayerInfo info) { if (client == null) throw new ArgumentNullException("client"); if (user == null) throw new ArgumentNullException("user"); if (info == null) throw new ArgumentNullException("info"); this.UserID = user.ID; this.ApplicationTag = info.ApplicationTag; this.BoardName = info.PlayerBoardName; this.CreatedOn = Convert.ToDateTime(info.PlayerDate, CultureInfo.InvariantCulture); this.Latitude = client.TryParseDouble(info.PlayerLatitude); this.Longitude = client.TryParseDouble(info.PlayerLongitude); this.Name = info.PlayerName; this.Rank = info.PlayerRank; }
internal Receipt(BuddyClient client, AuthenticatedUser user, InternalModels.DataContract_CommerceReceipt receipt) : base(client, user) { this.AppData = receipt.AppData; this.HistoryCustomTransactionID = receipt.HistoryCustomTransactionID; this.HistoryDateTime = DateTime.Parse(receipt.HistoryDateTime); this.ItemQuantity = int.Parse(receipt.ItemQuantity); this.ReceiptData = receipt.ReceiptData; this.ReceiptHistoryID = long.Parse(receipt.ReceiptHistoryID); this.StoreItemID = long.Parse(receipt.StoreItemID); this.StoreName = receipt.StoreName; this.TotalCost = receipt.TotalCost; this.UserID = long.Parse(receipt.UserID); this.VerificationResultData = !string.IsNullOrEmpty(receipt.VerificationResult) && bool.Parse(receipt.VerificationResult) ? this.VerificationResultData : ""; }
internal StoreItem(BuddyClient client, AuthenticatedUser user, InternalModels.DataContract_CommerceStoreGetItems storeItem) : base(client, user) { this.AppData = storeItem.AppData; this.CustomItemID = storeItem.CustomItemID; this.StoreItemID = storeItem.StoreItemID; this.ItemAvailableFlag = storeItem.ItemAvailableFlag == "true"; this.ItemCost = storeItem.ItemCost; this.ItemDateTime = DateTime.Parse(storeItem.ItemDateTime); this.ItemDescription = storeItem.ItemDescription; this.ItemDownloadUri = storeItem.ItemDownloadUri; this.ItemFreeFlag = storeItem.ItemFreeFlag == "true"; this.ItemIconUri = storeItem.ItemIconUri; this.ItemName = storeItem.ItemName; this.ItemPreviewUri = this.ItemPreviewUri; }
public void ResetModels(Dictionary <string, double> parameters) { InternalModels.Clear(); this.TrainCount = 0; this.ContextSet = false; this.LabelSet = false; this.sw = new Stopwatch(); this.IndicationStrength = new IndicationStrength(); this.IndicationStrengthPerLabel = new Dictionary <Label, IndicationStrength>(); int numberOfModels = (int)Math.Round(parameters["NumberOfModels"]); int maxNumberOfOperations = (int)Math.Round(parameters["MaxNumberOfOperations"]); int width = (int)Math.Round(parameters["Width"]); int height = (int)Math.Round(parameters["Height"]); for (int i = 0; i < numberOfModels; i++) { InternalModels.Add(FeatureModel.New(parameters)); } }
internal void GetPicturesInternal(int albumId, InternalModels.DataContract_VirtualPhotoAlbumInformation info, Action<BuddyCallResult<VirtualAlbum>> callback) { this.Client.Service.Pictures_VirtualAlbum_Get (this.Client.AppName, this.Client.AppPassword, this.AuthUser.Token, albumId.ToString (), (bcr) => { var result = bcr.Result; if (bcr.Error != BuddyError.None) { callback (BuddyResultCreator.Create<VirtualAlbum> (null, bcr.Error)); return; } VirtualAlbum album = new VirtualAlbum (this.Client, this.AuthUser, info); album.AddPictures (result); { callback (BuddyResultCreator.Create (album, bcr.Error)); return; } ; }); return; }
internal Place (BuddyClient client, AuthenticatedUser user, InternalModels.DataContract_SearchPlaces place) : base(client, user) { this.Address = place.Address; this.AppTagData = place.AppTagData; this.CategoryID = Int32.Parse (place.CategoryID); this.CategoryName = place.CategoryName; this.City = place.City; this.CreatedDate = Convert.ToDateTime (place.CreatedDate, CultureInfo.InvariantCulture); this.DistanceInKilometers = Double.Parse (place.DistanceInKilometers, CultureInfo.InvariantCulture); this.DistanceInMeters = Double.Parse (place.DistanceInMeters, CultureInfo.InvariantCulture); this.DistanceInMiles = Double.Parse (place.DistanceInMiles, CultureInfo.InvariantCulture); this.DistanceInYards = Double.Parse (place.DistanceInYards, CultureInfo.InvariantCulture); this.Fax = place.Fax; this.ID = Int32.Parse (place.GeoID); this.Latitude = Double.Parse (place.Latitude, CultureInfo.InvariantCulture); this.Longitude = Double.Parse (place.Longitude, CultureInfo.InvariantCulture); this.Name = place.Name; this.PostalState = place.PostalState; this.PostalZip = place.PostalZip; this.Region = place.Region; this.ShortID = place.ShortID; this.Telephone = place.Telephone; this.TouchedDate = Convert.ToDateTime (place.TouchedDate, CultureInfo.InvariantCulture); this.UserTagData = place.UserTagData; this.Website = place.WebSite; }
internal PicturePublic(BuddyClient client, InternalModels.DataContract_VirtualPhotoList photo) : base(client) { if (photo == null) throw new ArgumentNullException("photo"); this.FullUrl = photo.FullPhotoURL; this.ThumbnailUrl = photo.ThumbnailPhotoURL; this.Latitude = this.Client.TryParseDouble(photo.Latitude); this.Longitude = this.Client.TryParseDouble(photo.Longitude); this.AddedOn = photo.AddedDateTime; this.AppTag = photo.ApplicationTag; this.PhotoID = Int32.Parse(photo.PhotoID); this.UserId = Int32.Parse(photo.UserID); }
internal PicturePublic(BuddyClient client, User user, InternalModels.DataContract_PublicPhotoSearch photo, int userId) : base(client) { if (photo == null) throw new ArgumentNullException("photo"); this.FullUrl = photo.FullPhotoURL; this.ThumbnailUrl = photo.ThumbnailPhotoURL; this.Latitude = this.Client.TryParseDouble(photo.Latitude); this.Longitude = this.Client.TryParseDouble(photo.Longitude); this.AddedOn = Convert.ToDateTime(photo.PhotoAdded, CultureInfo.InvariantCulture); this.AppTag = photo.ApplicationTag; this.PhotoID = Int32.Parse(photo.PhotoID); this.User = user; this.UserId = userId; this.DistanceInKilometers = client.TryParseDouble(photo.DistanceInKilometers); this.DistanceInMeters = client.TryParseDouble(photo.DistanceInMeters); this.DistanceInMiles = client.TryParseDouble(photo.DistanceInMiles); this.DistanceInYards = client.TryParseDouble(photo.DistanceInYards); }
public static void SetInternalMode(this Player player, InternalModels model) { player.SetPrivateData(CounterStrikeOffset.internalmodel, (int)model); }
internal User(BuddyClient client, InternalModels.DataContract_ApplicationUserProfile applicationUserProfile) : this(client, Int32.Parse(applicationUserProfile.UserID)) { this.Name = applicationUserProfile.UserName; this.ID = Int32.Parse(applicationUserProfile.UserID); this.Gender = (UserGender)Enum.Parse(typeof(UserGender), applicationUserProfile.UserGender, true); this.Latitude = this.Client.TryParseDouble(applicationUserProfile.UserLatitude); this.Longitude = this.Client.TryParseDouble(applicationUserProfile.UserLongitude); this.LastLoginOn = DateTime.Parse(applicationUserProfile.LastLoginDate, CultureInfo.InvariantCulture); this.InitializeProfilePicture(applicationUserProfile.ProfilePictureUrl); this.CreatedOn = DateTime.Parse(applicationUserProfile.CreatedDate, CultureInfo.InvariantCulture); this.Status = (UserStatus)Int32.Parse(applicationUserProfile.StatusID); this.Age = Int32.Parse(applicationUserProfile.Age); }
public static void UnmakeVIP(this Player player, bool updateModel, bool updateScoreboard, InternalModels newModel) { player.SetVIP(false); if (updateModel) { player.SetInternalMode(newModel); player.UpdateUserInfo(player.InfoKeyBuffer); } if (updateScoreboard) { player.SendScoreAttribMessage(player.GetDefaultScoreBoardAttribute()); } }
internal void UpdateFromProfile (InternalModels.DataContract_FullUserProfile profile) { this.Name = profile.UserName; this.ID = Int32.Parse (profile.UserID); this.Gender = (UserGender)Enum.Parse (typeof(UserGender), profile.UserGender, true); this.ApplicationTag = profile.UserApplicationTag; this.Latitude = this.Client.TryParseDouble (profile.UserLatitude); this.Longitude = this.Client.TryParseDouble (profile.UserLongitude); this.LastLoginOn = Convert.ToDateTime (profile.LastLoginDate, CultureInfo.InvariantCulture); this.InitializeProfilePicture (profile.ProfilePictureUrl); this.CreatedOn = Convert.ToDateTime (profile.CreatedDate, CultureInfo.InvariantCulture); this.Status = (UserStatus)Int32.Parse (profile.StatusID); this.Age = Int32.Parse (profile.Age); this.Email = profile.UserEmail; this.LocationFuzzing = Boolean.Parse (profile.LocationFuzzing); this.CelebrityMode = Boolean.Parse (profile.CelebMode); }
internal User(BuddyClient client, InternalModels.DataContract_SearchPeople publicProfile) : base(client) { this.Name = publicProfile.UserName; this.ID = Int32.Parse(publicProfile.UserID); this.Gender = (UserGender)Enum.Parse(typeof(UserGender), publicProfile.UserGender, true); this.ApplicationTag = publicProfile.UserApplicationTag; this.Latitude = this.Client.TryParseDouble(publicProfile.UserLatitude); this.Longitude = this.Client.TryParseDouble(publicProfile.UserLongitude); //this.LastLoginOn = publicProfile.LastLoginDate; this.InitializeProfilePicture(publicProfile.ProfilePictureUrl); //this.CreatedOn = publicProfile.CreatedDate; this.Status = (UserStatus)Int32.Parse(publicProfile.StatusID); this.Age = Int32.Parse(publicProfile.Age); this.DistanceInKilometers = this.Client.TryParseDouble(publicProfile.DistanceInKilometers); this.DistanceInMeters = this.Client.TryParseDouble(publicProfile.DistanceInMeters); this.DistanceInMiles = this.Client.TryParseDouble(publicProfile.DistanceInMiles); this.DistanceInYards = this.Client.TryParseDouble(publicProfile.DistanceInYards); }
internal GamePlayer(BuddyClient client, AuthenticatedUser user, InternalModels.DataContract_GamePlayerSearchResults info) { if (client == null) throw new ArgumentNullException("client"); if (user == null) throw new ArgumentNullException("user"); if (info == null) throw new ArgumentNullException("info"); this.UserID = Int32.Parse(info.UserID); this.ApplicationTag = info.ApplicationTag; this.BoardName = info.PlayerBoardName; this.CreatedOn = Convert.ToDateTime(info.PlayerDate, CultureInfo.InvariantCulture); this.Latitude = client.TryParseDouble(info.PlayerLatitude); this.Longitude = client.TryParseDouble(info.PlayerLongitude); this.Name = info.PlayerName; this.DistanceInKilometers = client.TryParseDouble(info.DistanceInKilometers); this.DistanceInMeters = client.TryParseDouble(info.DistanceInMeters); this.DistanceInMiles = client.TryParseDouble(info.DistanceInMiles); this.DistanceInYards = client.TryParseDouble(info.DistanceInYards); this.Rank = info.PlayerRank; }
internal ApplicationStatistics(InternalModels.DataContract_ApplicationStats appStats, BuddyClient client) { if (client == null) throw new ArgumentNullException("client"); this.TotalUsers = appStats.TotalUsers; this.TotalDeviceInformation = appStats.TotalDeviceInformation; this.TotalCrashes = appStats.TotalCrashes; this.TotalAppMetadata = appStats.TotalAppMetadata; this.TotalAlbums = appStats.TotalAlbums; this.TotalFriends = appStats.TotalFriends; this.TotalGamePlayers = appStats.TotalGamePlayers; this.TotalGameScores = appStats.TotalGameScores; this.TotalMessages = appStats.TotalMessages; this.TotalPhotos = appStats.TotalPhotos; this.TotalPushMessages = appStats.TotalPushMessages; this.TotalUserCheckins = appStats.TotalUserCheckins; this.TotalUserMetadata = appStats.TotalUserMetadata; }
internal AuthenticatedUser (string token, InternalModels.DataContract_FullUserProfile profile, BuddyClient client) : base(client, Int32.Parse(profile.UserID)) { if (client == null) throw new ArgumentNullException ("client"); if (String.IsNullOrEmpty (token)) throw new ArgumentException ("Can't be null or empty.", "token"); this.Token = token; this.Metadata = new UserMetadata (client, token); this.IdentityValues = new Identity (client, Token); this.PhotoAlbums = new PhotoAlbums (client, this); this.VirtualAlbums = new VirtualAlbums (client, this); this.Friends = new Friends (client, this); this.PushNotifications = new Notifications (this.Client, this); this.Places = new Places (this.Client, this); this.Messages = new Messages (this.Client, this); this.Startups = new Startups (this.Client, this); this.Commerce = new Commerce (this.Client, this); this.GamePlayers = new GamePlayers (this.Client, this); this.Blobs = new Blobs(this.Client, this); this.Videos = new Videos(this.Client, this); this.UpdateFromProfile (profile); this.GameScores = new GameScores (this.Client, this, null); }
internal AuthenticatedUser (BuddyClient client, InternalModels.DataContract_ApplicationUserProfile profile) : base(client, Int32.Parse(profile.UserID)) { //this.Token = profile.user; <-- removed from contract (in ws) for security reasons this.Token = string.Empty; this.Metadata = new UserMetadata (client, this.Token); this.IdentityValues = new Identity (client, this.Token); this.PhotoAlbums = new PhotoAlbums (client, this); this.VirtualAlbums = new VirtualAlbums (client, this); this.Friends = new Friends (client, this); this.PushNotifications = new Notifications (this.Client, this); this.Places = new Places (this.Client, this); this.Messages = new Messages (this.Client, this); this.Startups = new Startups (this.Client, this); this.Commerce = new Commerce (this.Client, this); this.GamePlayers = new GamePlayers (this.Client, this); this.Blobs = new Blobs(this.Client, this); this.Videos = new Videos(this.Client, this); this.Name = profile.UserName; this.ID = Int32.Parse (profile.UserID); this.Gender = (UserGender)Enum.Parse (typeof(UserGender), profile.UserGender, true); this.Latitude = this.Client.TryParseDouble (profile.UserLatitude); this.Longitude = this.Client.TryParseDouble (profile.UserLongitude); this.LastLoginOn = Convert.ToDateTime (profile.LastLoginDate, CultureInfo.InvariantCulture); //fixes bug where DateTime.Parse was blowing up on non-US phones this.InitializeProfilePicture (profile.ProfilePictureUrl); this.CreatedOn = Convert.ToDateTime (profile.CreatedDate, CultureInfo.InvariantCulture); //fixes bug where DateTime.Parse was blowing up on non-US phones this.Status = (UserStatus)Int32.Parse (profile.StatusID); this.Age = Int32.Parse (profile.Age); this.Email = profile.UserEmail; this.LocationFuzzing = Boolean.Parse (profile.LocationFuzzing); this.CelebrityMode = Boolean.Parse (profile.CelebMode); }
internal User(BuddyClient client, InternalModels.DataContract_FriendRequests publicProfile, int userId) : this(client, Int32.Parse(publicProfile.FriendID) == userId ? Int32.Parse(publicProfile.UserID) : Int32.Parse(publicProfile.FriendID)) { this.ID = int.Parse(publicProfile.FriendID); this.Name = publicProfile.UserName; this.Gender = (UserGender)Enum.Parse(typeof(UserGender), publicProfile.UserGender, true); this.ApplicationTag = publicProfile.UserApplicationTag; this.Latitude = this.Client.TryParseDouble(publicProfile.UserLatitude); this.Longitude = this.Client.TryParseDouble(publicProfile.UserLongitude); this.LastLoginOn = publicProfile.LastLoginDate; this.InitializeProfilePicture(publicProfile.ProfilePictureUrl); this.CreatedOn = publicProfile.CreatedDate; this.Status = (UserStatus)Int32.Parse(publicProfile.StatusID); this.Age = Int32.Parse(publicProfile.Age); }