Recent Updates RSS Toggle Comment Threads | Keyboard Shortcuts

  • Jiang 5:39 pm on January 3, 2010 Permalink | Reply
    Tags: books, concurrent programming, parallel programming, reading   

    New Books to Read 

    Instead of doing new year’s resolutions, I’m going to set myself up for something more realistic: have a list of books that I want to read and digest the information contained. For now, these are the 2 books that have been on the shelf for quite some time and therefore what would be a better idea to start digging through.

    The obvious pattern here is that I’m finally going to take a more serious look at parallel programming. In the past, it’s been a mixture of rusty theory picked up back in the university and some anecdotal tips from MSDN articles and blog posts. Yes, you shouldn’t try to update controls in your worker thread. Yes, there are 4 conditions for deadlocks to occur in a system. But to say I really understand these, and the underlying framework, is a joke. Therefore, I set myself up to grasp these concepts better before Microsft new helper libraries simplify the implementation again.

     
  • Jiang 3:51 pm on December 29, 2009 Permalink | Reply
    Tags: design patterns, software-design   

    Design Patterns, Are They Important? 

    Ah, the good old design patterns. At one point, they seemed to be everywhere, especially when the Java reigned supreme in the enterprise space. The strange thing is that, as useful as they are, the majority of the code written out there do not use these patterns. I can think of 2 reasons:

    1. The code that gets written is unique enough that the same problem hasn’t recurred or a pattern hasn’t been identified.
    2. Programmers haven’t internalized to the extent that when they see a problem, they immediately recall the solution pattern.

    In the first case, there isn’t anything that needs to be addressed since if a pattern isn’t occurring, documenting its context and solution simply doesn’t justify the cost. How much time do you want to spend on detailing a really nifty hack that operates the LEDs to show the current time?

    On the other hand, when we fire up Visual Studio, there is a keen sense to just dive in and get started. Prototype codes are written as swiftly as possible to showcase the capability of the system. You really don’t want to get bogged down. When the time has come to properly design the software architecture, .NET idiosyncrasies often get in the way.You want to built a comment form? Web-form with postback is your friend. There are design patterns, just not Design Patterns as defined in the GoF book (Design Patterns: Elements of Reusable Object-Oriented Software).

    Who is to say that retrieving untyped dataset using the Enterprise Library and stored procedures isn’t a pattern that addresses the data access problem? Sure, the underlying code does use the Abstract Factory pattern. But so is the higher-level data access strategy, just not in the traditional sense.

    So my question is this. How big/mission-critical must the system be to justify the time  investment in adopting Design Patterns? Does the code base of Facebook, Twitter or for that matter, World of Warcraft apply many of the Patterns? If not, why are some of the throw-away type of reporting solutions commonly found in the .NET environment (grids) seem to stress on such things?

     
  • Jiang 1:39 pm on October 30, 2009 Permalink | Reply
    Tags: ,   

    SharePoint 2010 and Cocoa Touch 

    So finally Microsoft lifted the NDA on SharePoint 2010. I’ve been playing with the TAP builds and I have to say a lot of improvements on the user experience is certainly welcome. Case in point, remember content editor web part? The pain in the ass that requires you to edit the page, modify shared web part and edit rich text? It’s all gone now. The new CEWP is directly editable, just like its field control cousin. Nice touches like these certainly make end users a lot happier.

    As for developers, I think Linq to Sharepoint could potentially be huge. Now there is no need to open a separate tool just to generate those darn CAML codes. As usual, there are way too many improvements to iterate here. Oh, by the way, I’m heading off to Amsterdam next week for an entire week of SP2010 training. Hopefully, there will be something interesting that’s worth blogging about.

    And also, I’ve finally bought a MacBook Pro. Having drunk the .NET kool-aid since university days, this is not an easy decision to make. I feel that I’m at a stage where I want to explore the programming world outside of just .NET. I was struggling between all the cool RoR stuff and iPhone Cocoa Touch development. In the end, the chance of making some mobile apps won out. So hopefully, I’ll be writing some learning experience there as well.

     
  • Jiang 7:45 am on August 15, 2009 Permalink | Reply  

    An invitation to Google Wave Developer Sandbox 

    The invitation email has just landed in my inbox. w00t!

    Hi,

    You are being sent this mail because you requested access to the Google
    Wave Developer Sandbox. If you would still like a Google Wave Developer
    Sandbox account, please fill in this linked form:

    <URL redacted>

    After filling in this form, you should receive a mail with your account
    details within a few days.

    Hope to see you on Google Wave soon,

    - The Google Wave Team

     
  • Jiang 8:58 pm on August 13, 2009 Permalink | Reply  

    Designer vs Developer Tools 

    Originally I intended to title this post as Designers vs Developers but my strong bias towards developer made me think twice.  And the bias here is about the superiority of developers at all. By that, I meant I’ve always been a developer so my thoughts on this topic come largely from the experience of a developer.

    It’s widely accepted that Adobe and Microsoft each occupies the unchallenged position across this divide. Think graphic design tool out there and Photoshop will likely be the only thing  that comes to mind. On the other hand, think developer tool and Visual Studio comes out at the top again and again. Sure there are challengers like Eclipse, Xcode, GIMP and Inkspace but save for the fanatic few, most people would rather prefer to have the best tool for the job rather than spending a lot of time getting the tools to work together.

    Lately, partly due to the rise of RIA and the sudden focus on user experience, both companies took commendable efforts to show that their platform caters to the needs of both designers and developers alike. Adobe has Photoshop and Flex (to a small extent, Flash). See, turtleheads dance across all the various brushes, paths and etc on their elegant Wacom tablets. At the other side of the studio, introvert ActionScript ninjas type away furiously to create the next amazing site. Microsoft has a similar vision: designers work in Expression Design before passing their masterpieces to XAML pirates to implement the finishing touches.

    So far, so good. Or least that’s what they want us to believe. In reality, the story is more complicated. People often want to use Photoshop with Visual Studio and nothing else. That’s when a lot of unofficial tips and tricks come in. Heated exchanges ensue. “Why can’t you use Expression Blend and it makes my job so much easier?”. The designer shots back, “Why do you insist me on using something that’s be taken for serious jobs??”

    By now, the astute reader will observe that there isn’t mention of using Expression Blend with Flex. That’s true. I’ve yet to come across any team that dreams of such a combination. To put this in some perspective. Game studio have not had much problems working with a wide array of tools. Animators model character movements in Maya. Texture designers work with Photoshop. Developers code away with Visual Studio. There are attempts to ease the workflow across the team but generally, the teams just learn to work with one another to overcome any problem. I prefer the mantra of using the best tool for the job. There is no point in forcing your team to pick something that actually reduces their productivity simply because the various corporations want you to buy into their stack.

     
  • Jiang 2:53 pm on July 14, 2009 Permalink | Reply
    Tags:   

    My First Silverlight 3 Experience in HLSL 

    With great fanfare and astonishing speed, Silverlight has reached the magic version 3 (insert the cliché version 3 joke here) in a short time span of 22 month. There are several exciting features that came with it and I’m fascinated with the GPU processing aspect of it. It’s a big topic and details are not yet forthcoming but here is my initial understanding

    • GPU-assisted composition can be turned on to accelerate rendering. It caches the rendered bitmaps to avoid repetitive processing.
    • As of version 3, only pixel shader is supported. Vertex shader is not.
    • Pixel shader is processed with CPU, not GPU.
    • You use DirectX’s version of shader dialect called HLSL to create the effect file. Compile it and load them as a custom effect in Silverlight 3.

    First, you create a shader effect file.

    sampler2D input : register(s0);
    float4 main(float2 uv : TEXCOORD) : COLOR
    {
        float4 Color;
        Color = tex2D( input , uv.xy);
        Color -= tex2D(input , uv.xy-0.003)*2.7f;
        Color += tex2D( input , uv.xy+0.003)*2.7f;
        Color.rgb = (Color.r+Color.g+Color.b)/3.0f;
        return Color;
    }
    

    Invoke the effects compiler to generate a binary file.

    C:\Users\glenn.qiu\Documents\Visual Studio 2008\Projects\SilverlightApplication1\SilverlightApplication1>fxc /T ps_2_0 /Fo shader.ps shader.fx
    Microsoft (R) Direct3D Shader Compiler 9.26.952.2844
    Copyright (C) Microsoft Corporation 2002-2009. All rights reserved.

    compilation succeeded; see C:\Users\glenn.qiu\Documents\Visual Studio 2008\Projects\SilverlightApplication1\SilverlightApplication1\shader.ps

    Then you create a managed effect class to load the binary shader.

    public class MyPixelInvertedEffect : ShaderEffect
    {
        public MyPixelInvertedEffect()
        {
            this.PixelShader = new PixelShader() {
                UriSource = new Uri(&quot;/SilverlightApplication1;component/shader.ps&quot;, UriKind.Relative)
            };
        }
    }
    

    And lastly, attach the custom effect class to the element you want in XAML.

    &lt;userControl xmlns:controls=&quot;clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls&quot;  x:Class=&quot;SilverlightApplication1.MainPage&quot;
    xmlns=&quot;http://schemas.microsoft.com/winfx/2006/xaml/presentation&quot;
    xmlns:x=&quot;http://schemas.microsoft.com/winfx/2006/xaml&quot;
    xmlns:d=&quot;http://schemas.microsoft.com/expression/blend/2008&quot; xmlns:mc=&quot;http://schemas.openxmlformats.org/markup-compatibility/2006&quot;
    xmlns:shader=&quot;clr-namespace:SilverlightApplication1&quot;
    mc:Ignorable=&quot;d&quot; d:DesignWidth=&quot;640&quot; d:DesignHeight=&quot;480&quot;&gt;
    &lt;grid&gt;
    &lt;rectangle Width=&quot;357&quot; Height=&quot;143&quot;  Stroke=&quot;Black&quot; StrokeThickness=&quot;3&quot;&gt;
    &lt;rectangle.Fill&gt;
    &lt;imageBrush ImageSource=&quot;&lt;a href=&quot;http://silverlight.net/Themes/silverlight/images/logo.jpg&quot;&quot;&gt;http://silverlight.net/Themes/silverlight/images/logo.jpg&quot;&lt;/a&gt; /&gt;
    &lt;/rectangle.Fill&gt;
    &lt;rectangle.Effect&gt;
    &lt;shader:MyPixelInvertedEffect /&gt;
    &lt;/rectangle.Effect&gt;
    &lt;/rectangle&gt;
    &lt;/grid&gt;
    &lt;/userControl&gt;
    
     
  • Jiang 6:45 am on June 26, 2009 Permalink | Reply
    Tags: ,   

    Silverlight, Flash/AIR or HTML5? 

    update 1: data access and streaming details added with input from Ian in comments!

    update 2: HTML 5 offline and local storage added with input from Simone in comments!

    update 3: Ars Technica has a discussion around the complicated issue of finding a common codec.

    update 4: a more technical comparison is available here.

    It’s often argued that on the web, you can either achieve high reach or richness, but not both. By reach, they mean the number of users who can access the content on your website. On the other hand, by richness, they mean the overall experience in the presentation of the content. This worldview presents a dichotomy where none actually exists. It’s very tempting theory but I believe that it’s a mis-application of the Reach vs Richness theory in the browser space.

    Firstly, Flash has attained ubiquity on virtually all browsers (except mobile devices but Flash 10 is coming to Android, Symbian, Windows Mobile and WebOS). The claim that rich user experience is at odds with having to do everything with HTML and JavaScript is an uninformed one.

    They argue that you have no choice but to rely on proprietary plug-ins that are inherently non-ubiquitous. Also Flash and Silverlight are both proprietary plug-ins. Modus ponens,  there is no way to deliver richness unless you require users to install Flash or Silverlight. Of course, we know this isn’t true. Flash has already been installed and Silverlight is just something new that’s trying to gain market share. There are some statistics referring to a 25% penetration rate.

    That argument aside, the recent news about the emergence of HTML 5 and how it might obviate the need for browser plug-ins have got the developer world boiling. Despite the fact that it’s still a standard in the works, it aims to fill many gaps that are traditionally missing from HTML and JavaScript. In addition, being an industry standard means it has a much higher chance of reaching ubiquity, provided browser vendors do not intentionally create obstacles. In fact, Opera 10 already partially supports HTML5. So are Firefox 3.5, Chrome and Safari. The only guy late to the party is, of course, Internet Explorer.

    Let’s explore the feature set to see how HTML5 stacks against Silverlight and Flash/AIR.

    Silverlight Flash/AIR HTML 5
    MP3, AAC, WMA, WMV, VC-1, H.264 with DRM support MP3, MP4, M4V, M4A, 3GP, MOV, VP6 , H.264, Speex, with DRM support Fragmented: Ogg theora and H.264
    new
    XAML MXML HTML/XHTML
    C#/VB/IronPython/IronRuby ActionScript JavaScript
    UI Controls UI Controls Rudimentary UI Controls with 3rd party tools like jQuery UI
    GPU rendering with Bit Map Caching. Software-only HLSL Pixel Shader 2.0, no vertex shader GPU compositing.  Shading effects created using Pixel Blender processed by GPU. No GPU processing, pixel shader
    Offline mode AIR is the offline mode Offline HTTP Cache
    Isolated local storage SQLite support for local storage in AIR Native web storage
    Data access over WCF, POX and ADO.NET data services, TCP sockets Data access over web services, LiveCycle Data Services, BlazeDS and TCP sockets Data access over JSON
    MMS, RTSP, RTSPT, HTTP Streaming RTMP, RTMFP, HTTP Streaming Open web socket but not real time streaming
     
    • Ian Blackburn 3:02 pm on June 26, 2009 Permalink | Reply

      Nice comparison – thanks!

      Couple of point on Silverlight – it is not limited to WCF services – you can use REST, sockets, POX pretty much anything you want; and I am not exactly sure what you mean by streaming, but I think Silverlight has most of those bases covered too…

      Cheers

      Ian

    • Simone 8:43 am on July 4, 2009 Permalink | Reply

      Good comparison… I’d like to point out a few little imprecision:

      UI Controls: HTML5+JS has many not rudimentary UI controls… take a look at all the jQuery UI controls, or also the ones that come with the ASP.NET Ajax control toolkit, or ExtJS and so on… they don’t come out of the box with the “language”, but it’s easy to add them

      Offline mode and local storage: HTML5 has both offline mode and local storage, naively

  • Jiang 8:24 am on June 19, 2009 Permalink | Reply
    Tags:   

    SharePoint Variation Doesn't Mix with ASP.NET Web Parts 

    Found this gem today, nowhere in the SDK document did Microsoft mention this. They have a comparison table in choosing between ASP.NET or SharePoint web part as the base class but not this!

    Create a custom ASP.NET 2.0 Web Part Create a SharePoint-based Web Part
    • For most business needs.
    • To distribute your Web Part to sites that run ASP.NET 2.0 or SharePoint sites.
    • When you want to reuse one or more Web Parts created for ASP.NET 2.0 sites on SharePoint sites.
    • To use data or functionality provided by Windows SharePoint Services 3.0. For example, you are creating a a Web Part that works with site or list data.
    • When you want to migrate a set of Web Parts using the SharePoint-based Web Part infrastructure to Windows SharePoint Services 3.0.
    • To create cross page connections.
    • To create connections between Web Parts that are outside of a Web Part zone.
    • To work with client-side connections (Web Part Page Services Component).
    • To use a data-caching infrastructure that allows caching to the content database.
     
  • Jiang 5:05 pm on June 2, 2009 Permalink | Reply
    Tags:   

    Why Isn't There 13 Hive? 

    There is 60 Hive for SharePoint 2003/WSS 2.0. Then there is 12 Hive for SharePoint 2007/WSS 3.0. In the coming months, we will have 14 Hive for SharePoint 2010/WSS 4.0. So where is 13 Hive?

    Apparently, the product team is sensitive enough so that there isn’t going to be a code name called Office 13 due to its unlucky nature. Therefore, Office 14 follows Office 12 and its corresponding server product, SharePoint 14 will have 14 Hive.

     
  • Jiang 12:03 pm on May 19, 2009 Permalink | Reply
    Tags:   

    SharePoint Explorer View Error: "Your client does not support opening this list with Windows Explorer." 

    Despite the advances in the browser space, a majority of the corporate computers are still on Internet Explorer 6. Viewed with the fact that the current version of IE from Microsoft is already 8, and further that SharePoint 2010 will not support IE6, this is indeed backward.

    A colleague of mine encountered the problem of not being able to open Explorer View on her machine. Initial checks include the version of IE (running SP2), Trusted Sites Zone and ActiveX restrictions. There were nothing suspicious. Also, the WebClient service was running fine on the her machine.

    I came across this KB article that says IE6 has problems opening Explorer View when the URL is more than 100 characters. This was indeed the case. Apparently, she could either upgrade to IE7 (or IE 8 I presume) or apply a hotfix. (Note that this hotfix requires you to contact Microsoft Premier Support) The new problem was that her machine was already on IE6 SP2. So the hotfix wouldn’t even install. To try my luck, I went ahead to tweak the registry settings as detailed in the same KB article anyway. Voila, it worked!

     
  • Jiang 9:40 am on May 6, 2009 Permalink | Reply
    Tags: ,   

    The Appalling State of Small Investors on the Barclays Trading Platform 

    It’s widely held that timely access to the market is not essential to making investment decisions. The general buy and hold strategy do not require an investor to monitor the stock price on an intra-day basis (not even on daily close, some would say)

    However, when you only have a very small amount of cash to trade in stocks, every second counts. I don’t like the idea of buying into unit trusts or mutual funds as they tend to do no better than the index and charge hefty fees. I’m skittish with ETFs as my understanding of that asset class is rather basic.

    Barclays MarketMaster is a free trading account that imposes no inactivity fee if you make a transaction every quarter. Being free, I doubt if I can complain much about the appalling state of its service. Time and again, when I try to deal, it will time out or throw me to a more nasty error page like the one on the left.

    They do have a non-free tier 2 service called BARX. Is this a problem with the so-called freemium model? There is very little incentive to keep improving the basic service as they get revenue when a customer switches to the paid service.

    I do have another account with SelfTrade (ultimately owned by the Société Générale Group). Having used Barclays for the past 2-3 months, I really don’t want to switch yet. But if this keeps happening, there may be no choice.

     
  • Jiang 2:11 pm on May 1, 2009 Permalink | Reply
    Tags: , twitter   

    To Tweet or to blog, That is the Question 

    There has been so much media coverage about Twitter recently. If Stephen Fry, Oprah Winfrey, Britney Spears and Shaquille O’Neal are on twittering, then Twitter has really gone mainstream. Some early adopters have shown emotions of disdain and disgust along the line like “I really liked this band xxx before it’s gone main stream”. By analogy, would we quit in disdain when Paris Hilton is spotted using Ubuntu 13.04?

    Personally for me, I tried not once, but twice to really get Twitter. But I have 2 grudges against it.

    1. Indiscriminate broad-casting: there are people out there who tweets way too much. Every time you refresh, you end up seeing a full screen of updates from them.
    2. Lack of original content: a lot of tweets consist of links after links. So the experience is not unlike gaping at a massive link farm

    The 140 character limit is a joke for people who don’t use SMS to tweet. Why should there be such a limit when the majority of the tweets are sent from desktop/mobile clients. Detractors may say I just don’t get it. But why should we trade thoughtful writings for timeliness? In fact, to say there is such a trade off is overestimating the quality of content on Twitter. The majority tweets are meaningless and useless updates. Even more sinister is the action of RT (re-tweet). When something interesting happens, people just RT one another and fill up the space with identical content. Had those tweets been eliminated, there may be some space left to expand the 140 character limit?

    Blog, on the other hand, tends to focus on quality and originality. I’m sure there are blogs which merely re-posts. But more often than not, there are authors’ take and opinions.

    However, tweets can also be thought of as a stream of status updates and not meant to be read tweet by tweet. Viewed in this light, maybe I should really be less harsh at it.

     
  • Jiang 2:14 pm on April 30, 2009 Permalink | Reply
    Tags:   

    Windows SharePoint Services Web Application Stuck with Upgrading 

    As the Microsoft enterprise land explode into collective cheers with the release of SharePoint 2007 Service Pack 2, not everyone is happy. That is, if you encounter problems in upgrading your dutifully patched deployment to the latest iteration.

    So the web application service is stuck at upgrading. Rebooting the machine makes no difference and I suspect somewhere in the SharePoint_Config database, the value which indicates upgrading process is running is causing this to happen. Take a step back, this is a classic example of non-atomic operation. Two operations, writing the status to the database and upgrading the services happen in two steps and yet when upgrade fails, the value in the database is not rolled back. Anyway, someone showed how you can get rid of this by running the stsadm command.

    stsadm -o provisionservice -action start -servicetype SPWebService

    With this, the status is back to Started. Good, but when I tried to run SharePoint Products and Technologies Configuration Wizard, it complained about a difference error.

    Apparently, you can solve this problem by another stsadm command but it didn’t work for me.

    stsadm -o setproperty -pn command-line-upgrade-running -pv No

    In the spirit of discover-yet-another-command-line-operation, I just tried to force an upgrade. With SharePoint, the force parameter appears to be a way to forcefully bust through any checks from the databases and just do it.

    psconfig –cmd upgrade -force

    Ta-da, this marks the end of another day in the SharePoint land. Not for much longer though, SharePoint 2010 is coming soon.

     
  • Jiang 4:23 pm on April 25, 2009 Permalink | Reply
    Tags: investment, ,   

    Trading Stocks for Fun (and Potentially Profit) 

    Lately, the stocking market is having very irregular movements (financial geeks will call this as high volatility ) due to rapidly swinging investor sentiments. On 2008/10/15, Dow Jones Industrial Average (DJIA) lost 773 points (-7.87%), making it the 9th biggest percentage loss in index’s history. Two days before that, on 2008/10/13, it made the 5th largest one-day gain of 936 points (+11.08%). You can find the statistics here

    The performance of different sectors vary widely but most of them have been down significantly since the credit crunch started in 2007. Interestingly, the banking sector, which takes most of the blame on coming up with incredibly complex mathematical formulae by outsourcing risks, is the also the one that appears to be recovering swiftly. Well, at least for banks which are better run than its peers.

    So, for the past 2 months I’ve been playing with £1000 to try and understand a bit of the FTSE market through . Here are the trades so far.

    Deal Date Type Stock/Fund Name Quantity Price Debit Credit Profit
    13/03/2009 Buy BARCLAYS ORD GBP0.25 1246 78.77p £999.33 -£999.33
    16/03/2009 Sell BARCLAYS ORD GBP0.25 1246 85.02p £1,046.45 £47.12
    20/03/2009 Buy HSBC HLDGS ORD USD0.50(UK REG) 276 361.47p £1,015.60 -£968.48
    23/03/2009 Sell HSBC HLDGS ORD USD0.50(UK REG) 276 402.03p £1,096.65 £128.17
    20/04/2009 Buy BARCLAYS ORD GBP0.25 474 210.68p £1,016.57 -£888.40
    24/04/2009 Sell BARCLAYS ORD GBP0.25 474 233.11p £1,092.00 £203.60

    That’s a tidy profit of £203.60 over a period of 40 days. An interesting observation is that when the market is good, everyone can be a winner. I really don’t think the gains I made has anything to do with my stock picking skills but I don’t have any. However, as I remember from reading somewhere that most successful investors are those who see the upcoming sector instead of individual companies, I think the whole banking sector as a whole is really cheap at the moment. The same can perhaps be said about the automotive industry as well. But the story of Detroit automakers dominate the news and that doesn’t make it a particularly interesting sector to invest in.

     
  • Jiang 2:01 pm on April 15, 2009 Permalink | Reply
    Tags: ,   

    Strange Syntax of Objective-C No. 2 

    On the heel of interface declaration syntax we looked at earlier, today I’m going to talk briefly about properties.

    Officially, Apple calls properties as declared properties. Coming from a C# background, the first thing that springs to mind is declared properties are just like auto-implemented properties in C#. In a way, it’s similar but declared properties can have a lot of different behaviours beyond making them read-only. You can also specify the setter semantic and atomicity (critical in a multithreaded environment).

    Creating a property is a two-step process. First you have to declare it in the class interface and then in the implementation.

    @interface MyClass : NSObject
    {
        CGImageRef myImage;
    }
    
    @property(retain, nonatomic) CGImageRef myImage;
    @end
    
    @implementation MyClass
    @synthesize myImage;
    @end
    

    In the snippet, the property’s name is myImage and is of type CGImageRef. The words inside the brackets, retain and nonatomic, are its attributes. It indicates that when myImage is assigned to a new value, its own values should receive a release message while retain is invoked on the new value. nonatomic allows the getter to be interrupted by another thread. This is generally not a good idea unless you want to performance benefit and are sure there is no race condition.

    In the implementation, @synthesize keyword is used to let he compiler generate the necessary getter and setter methods.

    In this example, the property has the same name as the instance variable but you can specify a different name by specifying something like this.

    @synthesize ThisImage = myImage;
    

    In this way, the instance variable is myImage while the property name is now ThisImage.

    One last note, in objective-C, you don’t get the dot (.) notation that’s the standard way of accessing instance(class) methods and variables. You have to rely on the notion of message passing syntax.

    [theClass myImage];
    

    Assuming theClass is the object of the type MyClass, with the introduction of declared properties, you GET dot notation and therefore, theClass.myImage works. Hooray!!! Except, come on guys, so much for bringing the language to the 90s (or even 80s).

     
c
compose new post
j
next post/next comment
k
previous post/previous comment
r
reply
e
edit
o
show/hide comments
t
go to top
l
go to login
h
show/hide help
esc
cancel