nsset Questions

2

Solved

I am starting to look at CoreData and have two entities. These form a many to many relationship between Player: and Team: I am trying to iterate through the players of a team using a ForEach insi...
Jointure asked 13/1, 2021 at 15:31

3

Solved

I have a CoreData object that has an relationship that is NSSet. I'm trying to use this as my dataSource, but getting the following func tableView(tableView: UITableView, cellForRowAtIndexPath i...
Purree asked 9/10, 2016 at 15:39

6

Solved

I'm trying to update an MKMapView by removing all annotations outside the visible area, and adding and removing some annotations inside the visible area. This is my code: NSSet *visibleAnnotations...
Dentate asked 24/1, 2012 at 10:13

11

Solved

How can we create unique object list in Swift language like NSSet & NSMutableSet in Objective-C.
Desiccator asked 4/6, 2014 at 17:48

2

Solved

I have the following core data model: where Person to Codes is a one-to-many relationship. I have a function which returns a Person record and if the code person.codes returns an NSSet of all t...
Weswesa asked 22/11, 2018 at 20:52

8

Solved

If you can't get an object with objectAtIndex: from an NSSet then how do you retrieve objects?
Umbelliferous asked 30/9, 2010 at 0:7

1

Solved

I can convert from NSMutableSet to Set no problem, but I'm running into problems when doing the reverse. E.g. this works: let nsSet = NSMutableSet(array: ["a", "b"]) let swiftSet = nsSet as! Set&...
Peruse asked 27/2, 2018 at 20:26

3

Solved

I have some NSDictionary objects stored in an NSArray called telephoneArray. I fetch the values for the key number and then replace the NSDictionary I've just read with a new object at the same ind...
Neela asked 6/3, 2010 at 2:47

2

Solved

I query and get a NSSet which contains customer address from web. Since I'm new to objective c development I don't know how to get country,zip code etc from that set.So I followed Objective-C How t...
Hobo asked 2/12, 2016 at 11:32

3

Solved

I have a list of share prices with the properties dateTime and value. Currently I am sorting the share prices when fetching them using a sort descriptor. Now, I would like to change my code and ...
Gradin asked 25/4, 2013 at 14:46

6

Solved

What's the most efficient way to sort objects in an NSSet/NSMutableSet based on a property of the objects in the set? Right now the way I am doing it is by iterating through each object, add them t...
Downstairs asked 1/7, 2009 at 0:59

2

Solved

I am trying to move an objective C & CoreData app to Swift and iOS and hit a brick wall with iterating through NSSet objects: Xcode has generated these classes: class Response: NSManagedObje...
Moneybag asked 23/11, 2014 at 16:32

5

Solved

If you have an NSArray of strings { @"ONE", @"ONE", @"ONE", "TWO", @"THREE", @"THREE" } How would I turn that into { @"ONE", @"TWO", @"THREE" } ..where the array follows the same order as th...
Splenius asked 17/11, 2010 at 22:28

4

Solved

I have an NSSet of Strings, and I want to convert it into [String]. How do I do that?
Ballflower asked 27/7, 2015 at 20:8

4

Solved

I want to have a simple NSSet which is loaded with some NSNumbers and then find out if those numbers are already added in the set or not. When I do this: NSMutableSet *set = [[NSMutableSet alloc]...
Gallbladder asked 8/11, 2011 at 14:42

3

Solved

I have a list of custom objects being returned from a .NET WebService and am storing them using a To-Many relationship from the parent enitity with Core Data. I want to use the NSSet as the datas...
Pillowcase asked 4/10, 2010 at 15:32

2

Solved

With the original swift I could turn an NSSet (e.g. of Strings) into a typed array with the following syntax: var stringArray = exampleSet.allObjects as [String] With the new update I am getting...
Aft asked 6/3, 2015 at 17:39

1

I was wondering what is the big-O notation for iteration through NSSet. The answer for an NSArray is obviously O(n) - but what is the answer for NSSet? Also - I'm assuming the same answer would app...
Cloudland asked 4/10, 2014 at 15:9

3

Solved

I'm able to put the contents of an NSSet into an NSMutableArray like this: NSMutableArray *array = [set allObjects]; The compiler complains though because [set allObjects] returns an NSArray not...
Photostat asked 30/9, 2010 at 0:34

1

Solved

I might be missing something. But my current app on the appstore works in iOS 7, but in iOS 8 completely fails because it won't create a preallocated pool of sprites. They appear to be written to t...
Fleenor asked 9/9, 2014 at 22:14

1

Solved

I have a ManagedPhoto coredata object that contains a NSSet attribute called tags. Each object in the tags set is a NSString. I need to fetch all ManagedPhoto objects that have tags with a specifi...
Boorman asked 21/8, 2014 at 20:55

2

I've been trying to get my head around adding objects in relationships using CoreData and Swift. I am at a loss, I do not understand why my code does not work. I am trying to add an "Event" to a "T...
Filial asked 13/8, 2014 at 16:45

3

Solved

How do I merge 2 NSSets in objective-c ? I can't find solution on google.
Willyt asked 12/8, 2011 at 12:16

1

Solved

I have an NSMangedObject that contains NSSet of other NSManagedObjects. I need to check if these objects has an value in NSSet and then return them. I use MagicalRecord for fetching data. So I n...
Blatman asked 11/11, 2013 at 11:43

1

Solved

I have some problems about the NSMutableSet in Objective-C. I learnt that the NSSet will compare the two objects' hash code to decide whether they are identical or not. The problems is, I implement...
Fluff asked 25/10, 2013 at 2:15

© 2022 - 2024 — McMap. All rights reserved.