I'm three years late, but hopefully whoever else might be stuck on an issue like this will benefit from my answer.
# adds a LineLayerStyle (Arrow, dotted)
# layer being a vector layer object of QgsVectorLayer()
def setLineLayerStyle(self, layer, style):
if(style == "arrow"):
sl = QgsSymbolLayerV2Registry.instance().symbolLayerMetadata("LineDecoration").createSymbolLayer({ 'width' : '0.26', 'color' : '0,0,0' })
symbollist = layer.rendererV2().symbols()
symbol = symbollist[0]
symbol.appendSymbolLayer(sl)
Following this code, you will get a line that looks like the pink arrow. All of this information is from here