Search Results

Search found 173 results on 7 pages for 'ajsie'.

Page 7/7 | < Previous Page | 3 4 5 6 7 

  • how are association, aggregation and composition written?

    - by ajsie
    i have read some posts about the differences between these 3 relationships and i think i get the point. i just wonder, are all these written the same when coding? question 1: all 3 are just a value of the object type in a instance variable? class A { public $b = '' public function __construct($object) { $this->b = $object // <-- could be a association, aggregation or a composition relation? } } question 2: does it have to be an instance variable or can it be a static one? class A { public static $b = '' // <-- nothing changed? public function __construct($object) { $this->b = $object } } question 3: is there a difference in where the object is created? i tend to think that composition object is created inside the object: class A { public $b = '' public function __construct() { $this->b = new Object // is created inside the object } } and aggregation/association is passed through a constructor or another method: class A { public $b = '' public function __construct($object) { // passed through a method $this->b = $object } } question 4: why/when is this important to know. do i have to comment an object inside another what relation its about or do you do it in an UML diagram? could someone shed a light on these questions. thanks!

    Read the article

  • possible to make codeigniter work with another framework?

    - by ajsie
    the situation is this. my client (who also is a programmer) asks me to develop an address book (with mysql database) with a lot of functions. then he can interact with some class methods i provide for him. kinda like an API. the situation is that the address book application is getting bigger and bigger, and i feel like its way better to use CodeIgniter to code it with MVC. i wonder if i can use codeigniter, then in some way give him the access to controller methods. eg. in a controller there are some functions u can call with the web browser. public function create_contact($information) {..} public function delete_contact($id) {..} public function get_contact($id) {..} however, these are just callable from web browser. how can i let my client have access to these functions like an API? then in his own application he can use: $result = $address_book-create_contact($information); if($result) { echo "Success"; } $contact = $address_book-get_contact($id); is this possible? cause i just know how to access the controller methods with the webbrowser. and i guess its not an option for him to use header(location) to access them. all suggestions to make this possible are welcomed! thanks

    Read the article

  • comment code in netbeans?

    - by ajsie
    a while ago i could comment any code in php with netbeans like this: /* * * */ I just typed /* ENTER and netbeans gave me that lines above. then when i typed @ it gave me a full list of all available tags (author, param and so on). i reinstalled my mac and since then it hasnt worked. someone knows why and how i can activate it? i installed the netbeans for php only.

    Read the article

  • benefit of having a factory for object creation?

    - by ajsie
    I'm trying to understand the factory design pattern. I don't understand why it's good to have a middleman between the client and the product (object that the client wants). example with no factory: $mac = new Mac(); example with a factory: $appleStore = new AppleStore(); $mac = $appleStore->getProduct('mac'); How does the factory pattern decouple the client from the product? Could someone give an example of a future code change that will impact on example 1 negative, but positive in example 2 so I understand the importance of decoupling? Thanks.

    Read the article

  • onUpdate in MySQL means?

    - by ajsie
    i know that if you create a foreign key on a field (parent_id) in a child table that refer to a parent table's primary key (id), then if this parent table is deleted the child class will be deleted as well if you set onDelete to cascade when creating the foreign key in the child class. but what happens if i set it to onUpdate = cascade?

    Read the article

  • how to update and merge branch in netbeans?

    - by ajsie
    im using netbeans with svn. i've checked out a project and then i used "copy to..." and chose to copy the trunk to a branch. i deleted the working copy of the trunk and checked out the newly created branch into a working copy and made some changes both in the trunk and the branch. now..how do i update the branch with the new data of the trunk and how do i merge the branch with the trunk using netbeans? is this possible? cause with "merge to..." i could only chose to merge from a remote repository to a local folder.

    Read the article

  • using drupal 6 or 7 for a new PHP web application?

    - by ajsie
    if i create a new web application tomorrow, should i use Drupal 6 or 7? i have never used drupal before so i have to start learning it first (very familiar with PHP) so i can understand the basics and how to extend it. my concerns for using 7: no modules contributed yet? so i dont have all the fancy stuff i can add like in Drupal 6? no good documentation and lack of web tutorials? how could i learn about it if there is not that much support? too early in the development process? it's not stable enough? i would like to use 7 cause i dont want to relearn everything and 7 is indeed just around the corner. but im afraid that it lacks all other stuff version 6 has. could someone guide me into right direction? thanks

    Read the article

  • Great GUI for Apache2?

    - by ajsie
    I wonder if there are great GUI management tools for Apache so you dont have to manually edit files in VIM. It would be great if you could manage Apache over internet. Any suggestions of such tools?

    Read the article

  • mysql database design: threads and replies

    - by ajsie
    in my forum i have threads and replies. one thread has multiple replies. but then, a reply can be a reply of an reply (like google wave). because of that a reply has to have a column "reply_id" so it can point to the parent reply. but then, the "top-level" replies (the replies directly under the thread) will have no parent reply. so how can i fix this? how should the columns be in the reply table (and thread table). at the moment it looks like this: threads: id title body replies: id thread_id (all replies will belong to a thread) reply_id (here lies the problem. the top-level replies wont have a parent reply) body what could a smart design look like to enable reply a reply?

    Read the article

< Previous Page | 3 4 5 6 7