Sponsored Content
Full Discussion: AIX Basics
Operating Systems AIX AIX Basics Post 302536321 by narendram on Tuesday 5th of July 2011 05:34:15 AM
Old 07-05-2011
AIX Basics

Hello , Everyone ,

I want to know the Aix Basics and how it works ,hardware related problems and solution etc.
 

8 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Unix Basics

Hey, you said this forum was for Dummies, so don't blame me for the following! :D My whole "web building" life, I've had my sites hosted in one for or another. Lately, I've gotten into PHP and MySQL and, of course, those are also hosted for me. But lately, I've been thinking of using PHP and... (2 Replies)
Discussion started by: cap97
2 Replies

2. Shell Programming and Scripting

Shell basics

Hi All, I have a basic question in Scripting. Can anyone tell me what is the difference b/w the two syntax : if (( $lines = 0 )); and if ; when do we use the square brackets & when to use the paranthesis. Thanks, Pradeep (3 Replies)
Discussion started by: pradeep_desh
3 Replies

3. Shell Programming and Scripting

awk basics

what is wrong with the code below; it starts ,then does nothing, (even it doesn't end) #!/bin/awk x=1 b="foo" awk printf("%s got a %d on the last test\n","Jim",83) myout=("%s-%d",b,x) print myout (6 Replies)
Discussion started by: gfhgfnhhn
6 Replies

4. UNIX for Dummies Questions & Answers

basics - if condition (contains)

Can any body help me on how to check whether a file contains a required extension or not. pseudo is: if (filename contains .jpg || filename contains .gif) --- do some thing end if Example file names: test1.grm.gtrx.drx.jpg test.de.mi.jpg test2.ds.gif test3.gif thanks in advance (2 Replies)
Discussion started by: devs
2 Replies

5. AIX

DB2 basics

Dear friends I am going to study DB2 and i dont have any experience with any DB's.. Please provide me with some links or pdf's for DB2 starters. any advice will be very usefull (2 Replies)
Discussion started by: Vit0_Corleone
2 Replies

6. AIX

UNIX/AIX Performance Tuning = some basics please

Hi all, From Googling, I found that the basics used for troubleshooting UNIX/AIX performance issues are commands like vmstat, iostat and sar. I believe these are generic commands regardless of what UNIX flavour is in used, only difference being is the format of the output. In a real case... (2 Replies)
Discussion started by: newbie_01
2 Replies

7. UNIX for Dummies Questions & Answers

help me with basics

hello everyone i have to start with unix as it is a part of my training programme and i have to do a self study, i dont know where to start from. i need some basic questions to be answerd like why we use unix ? what is a terminal? what is an editor? why we write commands inside terminal? these... (4 Replies)
Discussion started by: aryancool
4 Replies

8. UNIX for Dummies Questions & Answers

UNIX basics

Hi, I am new to Unix. can you explain in brief with examples what is variable, what is argument and what is parameter? i searched a lot on other forums but not able to find a appropriate answer. thanks in advance!! (3 Replies)
Discussion started by: 21laps
3 Replies
Moose::Cookbook::Basics::Recipe8(3)			User Contributed Perl Documentation		       Moose::Cookbook::Basics::Recipe8(3)

NAME
Moose::Cookbook::Basics::Recipe8 - Builder methods and lazy_build VERSION
version 2.0205 SYNOPSIS
package BinaryTree; use Moose; has 'node' => (is => 'rw', isa => 'Any'); has 'parent' => ( is => 'rw', isa => 'BinaryTree', predicate => 'has_parent', weak_ref => 1, ); has 'left' => ( is => 'rw', isa => 'BinaryTree', predicate => 'has_left', lazy => 1, builder => '_build_child_tree', ); has 'right' => ( is => 'rw', isa => 'BinaryTree', predicate => 'has_right', lazy => 1, builder => '_build_child_tree', ); before 'right', 'left' => sub { my ($self, $tree) = @_; $tree->parent($self) if defined $tree; }; sub _build_child_tree { my $self = shift; return BinaryTree->new( parent => $self ); } DESCRIPTION
If you've already read Moose::Cookbook::Basics::Recipe3, then this example should look very familiar. In fact, all we've done here is replace the attribute's "default" parameter with a "builder". In this particular case, the "default" and "builder" options act in exactly the same way. When the "left" or "right" attribute is read, Moose calls the builder method to initialize the attribute. Note that Moose calls the builder method on the object which has the attribute. Here's an example: my $tree = BinaryTree->new(); my $left = $tree->left(); When "$tree->left()" is called, Moose calls "$tree->_build_child_tree()" in order to populate the "left" attribute. If we had passed "left" to the original constructor, the builder would not be called. There are some differences between "default" and "builder". Notably, a builder is subclassable, and can be composed from a role. See Moose::Manual::Attributes for more details. The lazy_build shortcut The "lazy_build" attribute option can be used as sugar to specify a whole set of attribute options at once: has 'animal' => ( is => 'ro', isa => 'Animal', lazy_build => 1, ); This is a shorthand for: has 'animal' => ( is => 'ro', isa => 'Animal', required => 1, lazy => 1, builder => '_build_animal', predicate => 'has_animal', clearer => 'clear_animal', ); If your attribute starts with an underscore, Moose is smart and will do the right thing with the "predicate" and "clearer", making them both start with an underscore. The "builder" method always starts with an underscore. You can read more about "lazy_build" in Moose::Meta::Attribute CONCLUSION
The "builder" option is a more OO-friendly version of the "default" functionality. It also separates the default-generating code into a well-defined method. Sprinkling your attribute definitions with anonymous subroutines can be quite ugly and hard to follow. AUTHOR
Stevan Little <stevan@iinteractive.com> COPYRIGHT AND LICENSE
This software is copyright (c) 2011 by Infinity Interactive, Inc.. This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. perl v5.12.5 2011-09-06 Moose::Cookbook::Basics::Recipe8(3)
All times are GMT -4. The time now is 06:25 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy