8 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I have connected to the source server by ftp command. when I tried to delete the file I am getting the permission error.
delete file1.txt
450 No permission to delete /today1/file1.txt
the files have below permission
150 File status okay; about to open data connection.
drwx------ 0 ... (3 Replies)
Discussion started by: ramkumar15
3 Replies
2. Web Development
Hi team,
How can I implement a users in MySQL database for Apache users, assuming that I'm using RHEL6. That is to say, how can I design this database and how let's Apache server know those user in this database.
Thanks in advance.. (3 Replies)
Discussion started by: leo_ultra_leo
3 Replies
3. UNIX for Dummies Questions & Answers
i wish to clear memory cache on a production box and i was wondering what is the worst that can happen if i do?
i already tested this on a backup server and everything seemed fine.
but i need to know from you experts what are the worst things that can happen when i run it on a real server:
... (5 Replies)
Discussion started by: SkySmart
5 Replies
4. Shell Programming and Scripting
#!/bin/bash
user=`mysql userList -uuserlist -puserlistpassword -s -N -e "SELECT userName FROM users WHERE activated='n'"`
for i in $user; do
useradd "$i" -m
doneThis is what I have done so far. But obviously it still does not work.
I'm trying to create users based on information stored in a... (5 Replies)
Discussion started by: bucketuk
5 Replies
5. UNIX for Dummies Questions & Answers
Hi,
i would like to enable all operations/connections to use a proxy server in a redhat server ,
witch file should i config to get this for all conections ....
Thanks (0 Replies)
Discussion started by: prpkrk
0 Replies
6. IP Networking
Hi,
I am involved in a project on Debian. One of my requirement is to route an IP packet in my application to a proxy server and receive the reply from the proxy server as an IP packet. My application handles data at the IP frame level. My application creates an IP packet(with all the necessary... (0 Replies)
Discussion started by: Rajesh_BK
0 Replies
7. Linux
i have installed a proxy server on my linux box .
how to get the IP for that proxy .
cheers (3 Replies)
Discussion started by: ppass
3 Replies
8. UNIX for Dummies Questions & Answers
I'm trying to get a Unix server on the internet (mostly for DNS requests) but this server is on a network behind a Proxy server. How can I configure my unix server that he will pass the proxy server for internet requests? (2 Replies)
Discussion started by: RSlegers
2 Replies
iCal::Parser(3pm) User Contributed Perl Documentation iCal::Parser(3pm)
NAME
iCal::Parser - Parse iCalendar files into a data structure
SYNOPSIS
use iCal::Parser
my $parser=iCal::Parser->new();
my $hash=$parser->parse($file);
$parser->parse($another_file);
my $combined=$parser->calendar;
my $combined=iCal::Parser->new->parse(@files);
my $combined=iCal::Parser->new->parse_files(@files);
my $combined=iCal::Parser->new->parse_strings(@strings);
DESCRIPTION
This module processes iCalendar (vCalendar 2.0) files as specified in RFC 2445 into a data structure. It handles recurrences ("RRULE"s),
exclusions ("EXDATE"s), event updates (events with a "RECURRENCE-ID"), and nested data structures ("ATTENDEES" and "VALARM"s). It currently
ignores the "VTIMEZONE", "VJOURNAL" and "VFREEBUSY" entry types.
The data structure returned is a hash like the following:
{
calendars=>[\%cal, ...],
events=>{yyyy=>{mm=>{dd}=>{UID=>\%event}}
todos=>[\%todo, ...]
}
That is, it contains an array of calendar hashes, a hash of events key by "year=>month=>day=>eventUID", and an array of todos.
Calendars, events and todos are "rolled up" version os the hashes returned from Text::vFile::asData, with dates replaced by "DateTime"
objects.
During parsing, events in the input calendar are expanded out into multiple events, one per day covered by the event, as follows:
o If the event is a one day "all day" event (in ical, the event is 24hrs long, starts at midnight on the day and ends a midnight of the
next day), it contains no "hour" field and the "allday" field is set to 1.
o If the event is a recurrence ("RRULE"), one event per day is created as per the "RRULE" specification.
o If the event spans more than one day (the start and end dates are on different days, but does not contain an "RRULE"), it is expanded
into multiple events, the first events end time is set to midnight, subsequent events are set to start at midnight and end at midnight
the following day (same as an "allday" event, but the "allday" field is not set), and the last days event is set to run from midnight
to the end time of the original multi-day event.
o If the event is an update (it contains a "RECURRENCE-ID"), the original event is updated. If the referenced event does not exist (e.g.,
it was deleted after the update), then the event is added as a new event.
An example of each hash is below.
Calendar Hash
{
'X-WR-CALNAME' => 'Test',
'index' => 1,
'X-WR-RELCALID' => '7CCE8555-3516-11D9-8A43-000D93C45D90',
'PRODID' => '-//Apple Computer\, Inc//iCal 1.5//EN',
'CALSCALE' => 'GREGORIAN',
'X-WR-TIMEZONE' => 'America/New_York',
'X-WR-CALDESC' => 'My Test Calendar',
'VERSION' => '2.0'
}
Event Hash
Note that "hours" and "allday" are mutually exclusive in the actual data. The "idref" field contains the "id" of the calendar the event
came from, which is useful if the hash was created from multiple calendars.
{
'SUMMARY' => 'overnight',
'hours' => '15.00',
'allday' => 1,
'UID' => '95CCBF98-3685-11D9-8CA5-000D93C45D90',
'idref' => '7CCE8555-3516-11D9-8A43-000D93C45D90',
'DTSTAMP' => \%DateTime,
'DTEND' => \%DateTime,
'DTSTART' => \%DateTime
'ATTENDEE' => [
{
'CN' => 'Jay',
'value' => 'mailto:jayl@my.server'
},
],
'VALARM' => [
{
'when' => \%DateTime,
'SUMMARY' => 'Alarm notification',
'ACTION' => 'EMAIL',
'DESCRIPTION' => 'This is an event reminder',
'ATTENDEE' => [
{
'value' => 'mailto:cpan@my.server'
}
]
}
],
}
Todo Hash
{
'URL' => 'mailto:me',
'SUMMARY' => 'todo 1',
'UID' => 'B78E68F2-35E7-11D9-9E64-000D93C45D90',
'idref' => '7CCE8555-3516-11D9-8A43-000D93C45D90',
'STATUS' => 'COMPLETED',
'COMPLETED' => \%DateTime,
'DTSTAMP' => \%DateTime,
'PRIORITY' => '9',
'DTSTART' => \%DateTime,
'DUE' => \%DateTime,
'DESCRIPTION' => 'not much',
'VALARM' => [
{
'when' => \%DateTime,
'ATTACH' => 'file://localhost/my-file',
'ACTION' => 'PROCEDURE'
}
],
},
Methods
new(%opt_args)
Optional Arguments
start {yyymmdd|DateTime}
Only include events on or after "yyymmdd". Defaults to Jan of this year.
end {yyyymmdd|DateTime}
Only include events before "yyymmdd".
no_events
Don't include events in the output (todos only).
no_todos
Don't include todos in the output (events only).
months n
DateTime::Sets (used for calculating recurrences) are limited to approximately 200 entries. If an "end" date is not specified, the "to"
date is set to the "start" date plus this many months. The default is 60.
tz string
Use tz as timezone for date values. The default is 'local', which will adjust the parsed dates to the current timezone.
debug
Set to non-zero for some debugging output during processing.
parse({file|file_handle}+)
Parse the input files or opened file handles and return the generated hash.
This function can be called mutitple times and the calendars will be merge into the hash, each event tagged with the unique id of its
calendar.
parse_files({file|file_handle}+)
Alias for "parse()"
parse_strings(string+)
Parse the input strings (each assumed to be a valid iCalendar) and return the generated hash.
AUTHOR
Rick Frankel, cpan@rickster.com
COPYRIGHT
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
The full text of the license can be found in the LICENSE file included with this module.
SEE ALSO
Text::vFile::asData, DateTime::Set, DateTime::Span, iCal::Parser::SAX
perl v5.10.1 2008-05-30 iCal::Parser(3pm)