property

Programmatically bind property to GridViewColumn.Width

I got a WPF MVVM application containing a ListView containing a GridView. Using a helper class I'm creating the GridViewColumn's, which works nicely. My problem: I want to twoway-bind the width so I can read back changes to the width. The code to create the GridViewColumn right now looks like this: private static GridViewColumn Create...

CABasicAnimation not animating my property

I've been trying to understand what is wrong with my animation and I still haven't figure it out. I think it should be really straight forward, but there is probably something I'm missing, even after reading lot of examples and documentation. My problem comes originally form the fact that on the iPhone, you cannot resize layers automati...

Ant: Concatenate properties from a fileset

Hi everyone, I am trying to do the following in ANT but I am stuck. Read which projects are installed in my project workspace. workspace buildtools build.xml project1 build.xml project.name = "project1" IP = "44.55.66.77" SERVER_NAME = "project1.local" DOCUMEN...

Ant Fileset Expansion doesn't work

Hello everyone, I get a very confusing reaction from my ant build-file and I'm wondering whether I'm just not clever enough or this might actually be a bug. I've got the following property set globally in my project: <property name="lib.dir" location="lib"/> Then I'll try to add some files out of this directory into a jar file via f...

Using Python property() inside a method.

Assuming you know about Python builtin property: http://docs.python.org/library/functions.html#property I want to re-set a object property in this way but, I need to do it inside a method to be able to pass to it some arguments, currently all the web examples of property() are defining the property outside the methods, and trying the ob...

How to override a static property of a parent object and let the parent object access the new value in PHP?

This is what I have: All objects that can be persisted on the database extend the DatabaseObject abstract class, which has all the logic code to actually watch for attribute changes and run the databas queries. I'm using two static variables to define object-specific details. I define them generically in the base class, and then suppose...

Private or Protected Set for a MustOverride Property

I'd like to have a Private or Protected "Setter" for a property that also happens to be an abstract (MustOverride). I'm porting some code from C# to VB and in C# this is pretty straight forward. In VB not so much (for me anyway). Some code... In C#... public abstract class BaseClassWithAnAbstractProperty { public abstract int AnAb...

What's the purpose of an ivar when a property exists?

The following doesn't complain at compilation nor runtime about no name ivar. So why is it so common to see an ivar and @property/@synthesize. @interface PropTest : NSObject { } @property (retain) NSString *name; @end @implementation PropTest @synthesize name; @end int main (int argc, const char * argv[]) { NSAutoreleasePool * pool ...

Dynamic deep selection for a JavaScript object

With a single property this is fairly easy: var jsonobj = { "test": "ok" } var propname = "test"; // Will alert "ok" alert(jsonobj[propname]); But what I want to do is use a nested property: var jsonobj = { "test": { "test2": "ok" } } var propname = "test.test2"; // Alerts undefined alert(jsonobj[propname]); I...

Easy creation of properties that support indexing in C#

In C# I find indexed properties extremely useful. For example: var myObj = new MyClass(); myObj[42] = "hello"; Console.WriteLine(myObj[42]); However as far as I know there is no syntactic sugar to support fields that themselves support indexing (please correct me if I am wrong). For example: var myObj = new MyClass(); myObj.field...

commiting only the property change of a folder not the modified files inside it using svn commit.

hi i want to commit only the property of a folder not the locally modified files inside it. when i am using svn commit it is commiting also the modified files.please tell me how to get this . thanks ...

How to manage poperty files for different application instances?

Hi All! I think in our project we have the common problem for really big projects... We have 4 regions in which our system is installed - Europe, USA, ASIA and Japan.. Each region has 3 types of environment - dev, test and prod. For each environment we have property file where we are specifying configurations for instances. In whole we ...

When should uiviewcontrollers be declared as properties

Well this has been bugging me for quite a while so now i'll ask When should uiviewcontrollers be declared as properties? I noticed that in many examples uiviewcontrollers that are being pushed and popped on a uinavigation controller are not declared as properties. I took that forward and now every uiviewcontroller i use inside my code ...

Set a default value to a property and make it serializable.

Hi, I need to set a default value for a property, but I can't do it like this: private int prop = 1; public Prop { get {return prop;}... } Because I need to serialize this class, and if I do it, I loose the default value. Exists any solution that works after the serialization and before, adding an attribute to the property or somet...

Adding a property without touching the class? (not inheritance)

I got a requirement in my project to add another property to some class. Now I want to avoid changing the class because I figured it shouldn't be aware that he has this property (this property only has significance in the context of this project). The way I thought to accomplish this was (Please critic this because I wanna know if there...

Python property and method override issue: why subclass property still calls the base class's method

Here is an example class A(object): def f1(self): return [] test1 = property(f1) class B(A): def f1(self): return [1, 2] if __name__ == "__main__": b = B() print b.test1 I expect the output to be [1, 2], but it prints [] instead. It is contrary to my expec...

Controlling the sort order of property pages in a eclipse property dialog

Currently, when I contribute property pages to Eclipse using the org.eclipse.ui.propertyPages extension point, the individual property pages show up in the property dialog in alphabetical order based on the pages name. Is there a way to control the order that property pages are listed? I want the basic property page to always show up f...

Undefined property error with Event.CLOSING

I was using the Flex 3.5 + AIR 2 beta 2 SDK for some time now for one of my projects. Moving to the final 3.5 release today causes the compilation to fail with the following error. Error: Access of possibly undefined property CLOSING through a reference with static type Class. This happens in the following line. this.addEventListener(...

Flex 3 to Flex 4 Conversion and Undefined Methods

I have an application I am attempting to convert from a flex 3 air application to a flex 4 air application. I am running into an issue in my main class. When calling the Instance method on the class I am getting an error: Access of possibly undefined property Instance through a reference with static type Class. My main class is pretty...

FXCop warning CA1801: "Parameter is never used..." on overridden inherited supressed property

On a continued mission to clean up the codebase I inherited, via stylecop and fxcop, and one of the warnings from fxcop was CA1801: Parameter 'value' of Something.MyProperty.set(string) is never used. Remove the parameter or use it in the method body. The code it complains about is: public class Something : ISomeInterface public ne...