Questions tagged [custom-object]
187 questions
112
votes
2 answers
Getting a Custom Objects properties by string var
Possible Duplicate:
javascript object, access variable property name?
Trying to get more advanced in my JS...
I have a custom object:
Object myObject = new Object();
myObject.thing = anythingHere;
I would like to be able to retrieve a custom…
![](../../users/profiles/895396.webp)
Jay-Nicolas Hackleman
- 1,265
- 2
- 9
- 7
66
votes
9 answers
Searching in a ArrayList with custom objects for certain strings
I have a ArrayList with custom objects. I want to search inside this ArrayList for Strings.
The class for the objects look like this:
public class Datapoint implements Serializable {
private String stateBased;
private String name;
private…
![](../../users/profiles/1582279.webp)
Mokkapps
- 1,978
- 9
- 38
- 64
24
votes
4 answers
Type safety: Unchecked cast from Object to List
I have a ListView listing a custom object (let's say MyObject).
I want to filter it dynamically through an EditText so I had to implement a getFilter() with a publishResults method:
@Override
protected void publishResults(CharSequence constraint,…
![](../../users/profiles/1178445.webp)
Eloi Navarro
- 1,355
- 1
- 13
- 26
9
votes
2 answers
Rendering a JSON object of a join-model and its associated models
In a Rails ( 4.1.5 / ruby 2.0.0p481 / win64 ) application I have a many-to-many relationship between Student and Course and a join model StudentCourse which represents the association, and has an additional attribute called started (set by default…
![](../../users/profiles/988591.webp)
jj_
- 2,548
- 28
- 55
7
votes
1 answer
Swift: Store arrays of custom classes in Core Data
I'm new to Core Data but for a new project of mine, I would like to save my data to Core Data.
I want to create a Reptile-class which contains a couple of custom class arrays. Without Core Data I would have something like this:
import…
![](../../users/profiles/5149688.webp)
Kevin De Koninck
- 144
- 1
- 12
7
votes
5 answers
how to send a custom object as Job Parameter in Spring Batch?
I have a requirement of sending a Custom Object to the Spring Batch Job , where this Object is used continuously used by the Item Processor for the business requirement.
How can we send custom object from outside to the Job Context. This Object…
![](../../users/profiles/4424875.webp)
ravinder reddy
- 229
- 1
- 4
- 14
7
votes
4 answers
Passing custom List of data using Bundle
I'm developing a simple app, that contains tabview with fragment. I am stuck at the place, where i have to pass data to my newly created fragment on tabselect.
I have a List of lists of my custom class objects:
List
- >…
![](../../users/profiles/2408478.webp)
xenuit
- 97
- 1
- 1
- 9
7
votes
3 answers
Implementing hashcode and equals for custom classes
So I have many custom classes are also have custom clases inside of them using composition.
My custom classes have variables that change very frequently and I add them to HashSets. So my question is when I implement hashCode
- what should I do for…
![](../../users/profiles/1495015.webp)
Wang-Zhao-Liu Q
- 12,331
- 27
- 70
- 106
6
votes
1 answer
Powershell Custom Objects: How To Acess NoteProperty of collected result
Reading through an Article about custom Objects:
http://technet.microsoft.com/en-us/library/ff730946.aspx
I wonder why i get a result for the individual entry: e.g $objAverage.Name
while by $colAverages.Name nothing is returened.
Although with…
![](../../users/profiles/232756.webp)
icnivad
- 2,061
- 7
- 28
- 34
6
votes
2 answers
iOS custom object initialization Error
I have a custom object ProductCategory.
.h file:
#import
@interface ProductCategory : NSObject
@property int productCategoryId;
@property NSString *name;
@property NSArray *children;
@property int parentCategoryId;
-…
![](../../users/profiles/2274847.webp)
Ale
- 2,051
- 3
- 34
- 61
5
votes
3 answers
What is the best way to save an NSMutableArray to NSUserDefaults?
I have a custom object called Occasion defined as follows:
#import
@interface Occasion : NSObject {
NSString *_title;
NSDate *_date;
NSString *_imagePath;
}
@property (nonatomic, retain) NSString *title;
@property…
![](../../users/profiles/850350.webp)
Ali
- 4,135
- 4
- 22
- 39
5
votes
3 answers
How to get the unique id's of objects in an array swift
I have a custom class like this -
class Event: NSObject
{
var eventID: String?
var name:String?
}
Now i have an array of Event object's like
var events = [Event]()
var event1 = Event()
event1.eventID = "1"
event1.name = "Anu"
var…
![](../../users/profiles/1838025.webp)
Anupam Mishra
- 2,866
- 2
- 28
- 55
5
votes
6 answers
Set custom class object's value with '=' operator in Java
I have a custom object that has a single value of type int that I wanting to do processing on to keep this value in a set range. My question is this: Given the following class, can I set it's value with myObject = 0;
public class foo{
private…
![](../../users/profiles/1163705.webp)
Xandor
- 430
- 1
- 7
- 17
4
votes
1 answer
iCloud - How to save archive containing array of custom objects
I have developed a small app that stores locally in iOS through archiving an array of custom objects containing:
@property (nonatomic, copy) NSString *name;
@property (nonatomic, copy) NSString *dateCreated;
@property (nonatomic, copy)…
![](../../users/profiles/1079170.webp)
Will
- 303
- 3
- 9
3
votes
2 answers
Finding matches in arrays of objects in Powershell
I'm using custom objects to hold the name and schema from a set of SQL Server objects. I put the objects into an array, then I get another set of objects and put those into another array. What I'd like to do now is find all exact matches between the…
![](../../users/profiles/5696608.webp)
Tom H
- 44,871
- 12
- 81
- 121