How to Create a TimelineItemProcessor that adds attachments to items that have already passed through the pipeline

1 view
Skip to first unread message

Palak

unread,
Jul 20, 2011, 3:23:00 AM7/20/11
to Seesmic Desktop Platform Development
Hi
I've created a plugin that creates 2 custom columns, registers a
search provider. I created a TimelineItemProcessor in the plugin but
it only runs when a new item is added to the pipeline. How do I add
attachments to items that have already been retrieved and passed
through the pipeline?

Thanks

Palak

George Ionita

unread,
Jul 20, 2011, 4:23:05 AM7/20/11
to seesmic-d...@googlegroups.com
Hi Palak,

You can import ISessionService and you'll find there a TimelinItemContainers collection that should give you what you seek. But please take all the cautions to avoid performance bottlenecks when processing that list because it can get HUGE.

Thanks,
George

Palak

unread,
Aug 3, 2011, 4:10:01 AM8/3/11
to Seesmic Desktop Platform Development
Hi George,

Thanks for the response. I tried Importing the SessionService in my
DataProvider plugin but I get a NullReferenceException on application
start up if I use a foreach statement to iterate through the
TimelineItemContainers. Can you give a small example of how to use the
ISessionService?

Thanks

Palak

Palak

unread,
Aug 3, 2011, 4:14:32 AM8/3/11
to Seesmic Desktop Platform Development
I also tried putting the code that adds an attachment to the
timelinecontainer in the OnItemProcessed method of the DataProvider
but that didn't work either.

Palak

George Ionita

unread,
Aug 3, 2011, 9:19:14 AM8/3/11
to seesmic-d...@googlegroups.com
Hi Palak,

Which instance is null when you get the exception? Is it the IShellService or it's the items collection?

George

Palak

unread,
Aug 3, 2011, 2:37:35 PM8/3/11
to Seesmic Desktop Platform Development
Hi George,

I can't attach the debugger fast enough to the Seesmic application to
find out which instance is null.
BTW I'm importing and using the SessionService to get the
TimelineContainer collection NOT the IShellService.
I do this in the Start method of the DataProvider Plugin. That's why
Seesmic throws the exception on start up.
The strange thing is that even though I get a big red exception
message when I start Seesmic I still get notifications (as pop ups on
the bottom right corner) from the twitter and facebook accounts I've
associated with my Seesmic Desktop application.

The DataProvider plugin already has code that registers sidebar
actions and creates custom columns and registers a search provider.
All that functionality is working just great. It's when I add code to
the Start method that accesses the ISessionService that I've imported
that I get the exception.

I'll modify the code to find out if it's the Session Service that's
null or the collection.

Thanks

Palak

On Aug 3, 6:19 am, George Ionita <geo...@seesmic.com> wrote:
> Hi Palak,
>
Reply all
Reply to author
Forward
0 new messages