I am new to Object oriented programming in perl. So, I have a silly question. 

What --
I am writing a script which will do something and write result to stream ( STDOUT or NETWORK ). 

How --

[main.pl]

```
#!/usr/bin/perl
use strict;

require const::StreamTypes;
require output;

my $out = output->new("output");

$out->writeLine("Sample output");

```

[output.pm]

```
#!/usr/bin/perl
use strict;

require const::StreamTypes;

package output;

my $OUTSTR;

sub new{

    my $class   = shift();
    my $stream  = shift();

    if($stream eq const::StreamTypes->STDNET){

    }elsif($stream eq const::StreamTypes->STDWEB){

    }else{
        *OUTSTR = *STDOUT;
    }   

    my $self    = {
        "_outStream"    => $stream,
        "_outStreamPtr" => $OUTSTR
    };

    bless($self, $class);
}

sub writeLine{
    my $msg = shift();
    print(OUTSTR "$msg\n");
}

return 1;

```

So, can anyone help me understand what is going wrong here? 'cas program runs without error but with no output.

Thanks!