[Gephi-plugins] Proper way of using customized attribute columns

Mathieu Bastian mathieu.bastian at gmail.com
Wed Nov 3 23:48:18 CET 2010


Hi Shaun,

That seems correct, I'll check it out if something is wrong on my side.

Mathieu

On Wed, Nov 3, 2010 at 8:25 PM, Shaun Roach <sroach at alchemyapi.com> wrote:

> Hello,
>
> I am trying to fix my plugin.  On the newest release of Gephi, it crashes
> when I attempt to use new attribute columns.
> Here is how I am trying to set these columns:
>
> AttributeTable nodeTable = attributeModel.getNodeTable();
> AttributeColumn inCol = nodeTable.addColumn("alchemyrelevance", "AlchemyAPI
> Relevance", AttributeType.DOUBLE, AttributeOrigin.DATA, 0.0);
>
> NodeDraft firstNode = container.factory().newNodeDraft();
> firstNode.addAttributeValue(inCol,  0.75);
>
> When I do this I get an exception :
>
> java.lang.IllegalArgumentException: The value column doesn't exist
>         at
> org.gephi.data.attributes.AttributeRowImpl.setValue(AttributeRowImpl.java:109)
>         at
> org.gephi.data.attributes.AttributeRowImpl.setValue(AttributeRowImpl.java:101)
>         at
> org.gephi.io.importer.impl.NodeDraftImpl.addAttributeValue(NodeDraftImpl.java:215)
>         at
> com.alchemyapi.gephi.plugin.AlchemyAction.generate(AlchemyAction.java:151)
>
>
> What's the proper way to put an attribute value into a new NodeDraft for my
> generator?
>
> Thanks for your help!
>
> Shaun
>
>
>
> _______________________________________________
> gephi-plugins mailing list
> gephi-plugins at lists.gephi.org
> http://gephi.org/mailman/listinfo/gephi-plugins
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://gephi.org/pipermail/gephi-plugins/attachments/20101103/3cf1236c/attachment.html>


More information about the gephi-plugins mailing list